diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2014-01-03 15:32:27 -0500 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2014-01-03 15:32:27 -0500 |
| commit | ecc6fcfbab7006c7c9bfcf76d329c663a2fa5a2c (patch) | |
| tree | d849f61148c2da3c2323379413682dc5f4448a00 /MediaBrowser.Controller/Entities/Video.cs | |
| parent | ede84702d1805fac2f452bf298e59549893baea5 (diff) | |
add custom collection sort orders to edit page
Diffstat (limited to 'MediaBrowser.Controller/Entities/Video.cs')
| -rw-r--r-- | MediaBrowser.Controller/Entities/Video.cs | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/MediaBrowser.Controller/Entities/Video.cs b/MediaBrowser.Controller/Entities/Video.cs index 19cad7948..8ca475650 100644 --- a/MediaBrowser.Controller/Entities/Video.cs +++ b/MediaBrowser.Controller/Entities/Video.cs @@ -238,7 +238,7 @@ namespace MediaBrowser.Controller.Entities if (string.IsNullOrEmpty(parentPath)) { - throw new ApplicationException("Unable to get parent path info from " + path); + throw new IOException("Unable to get parent path info from " + path); } files = new DirectoryInfo(parentPath) @@ -247,7 +247,14 @@ namespace MediaBrowser.Controller.Entities } else { - files = ResolveArgs.FileSystemChildren.Where(i => + var resolveArgs = ResolveArgs; + + if (resolveArgs == null) + { + throw new IOException("ResolveArgs are null for " + path); + } + + files = resolveArgs.FileSystemChildren.Where(i => { if ((i.Attributes & FileAttributes.Directory) == FileAttributes.Directory) { |
