mrlucas84 / embermediamanager

Automatically exported from code.google.com/p/embermediamanager
0 stars 0 forks source link

BUG*** If no Writer on IMDB fail to Load All nfo #135

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Me again.. this one is bad
If no Writer on IMDB will cause exception GetMovieInfo not loading all IMDB
kinfo leaving nfo blank

Possible patch :)

Index: clsScrapeIMDB.vb
===================================================================
--- clsScrapeIMDB.vb    (revision 264)
+++ clsScrapeIMDB.vb    (working copy)
@@ -621,8 +621,9 @@
                             AndAlso Not M.Groups("name").ToString = "(more)" _
                             AndAlso Not M.Groups("name").ToString = "(WGA)" _
                             Select Writer =
Web.HttpUtility.HtmlDecode(String.Concat(M.Groups("name").ToString,
If(FullCrew, " (writer)", String.Empty)))
-
-                    IMDBMovie.Credits = Strings.Join(q.ToArray, " / ").Trim
+                    If q.ToArray.Length > 0 Then
+                        IMDBMovie.Credits = Strings.Join(q.ToArray, " /
").Trim
+                    End If
                 End If

                 If bwIMDB.WorkerReportsProgress Then

Original issue reported on code.google.com by nfnovais@gmail.com on 8 Jun 2009 at 10:57

GoogleCodeExporter commented 9 years ago
lol the only one I didn't add a count check *sigh* lol Instead of 
q.toarray.length I
just used q.count ;)

Original comment by jason.schnitzler on 9 Jun 2009 at 1:05

GoogleCodeExporter commented 9 years ago

Original comment by jason.schnitzler on 14 Jun 2009 at 8:57