Explorar el Código

add null check to SyncJobProcessor

Luke Pulverenti hace 9 años
padre
commit
c3eb571d1d
Se han modificado 1 ficheros con 5 adiciones y 0 borrados
  1. 5 0
      MediaBrowser.Server.Implementations/Sync/SyncJobProcessor.cs

+ 5 - 0
MediaBrowser.Server.Implementations/Sync/SyncJobProcessor.cs

@@ -308,6 +308,11 @@ namespace MediaBrowser.Server.Implementations.Sync
                     throw new ArgumentException("Unrecognized category: " + category);
             }
 
+            if (parent == null)
+            {
+                return new List<BaseItem>();
+            }
+
             query.User = user;
 
             var result = await parent.GetItems(query).ConfigureAwait(false);