diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2014-02-13 00:11:54 -0500 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2014-02-13 00:11:54 -0500 |
| commit | eec9e0482525c400e9dc7cb17bc000434adba105 (patch) | |
| tree | 73f51bc882804ff92b82d1e85a46a6cec10b6d51 /MediaBrowser.ServerApplication/ApplicationHost.cs | |
| parent | 9254c37d52af3d16ec9e46b3e211ecc7dc4f1617 (diff) | |
take photos into the core
Diffstat (limited to 'MediaBrowser.ServerApplication/ApplicationHost.cs')
| -rw-r--r-- | MediaBrowser.ServerApplication/ApplicationHost.cs | 47 |
1 files changed, 46 insertions, 1 deletions
diff --git a/MediaBrowser.ServerApplication/ApplicationHost.cs b/MediaBrowser.ServerApplication/ApplicationHost.cs index 695697f8f..5af08073b 100644 --- a/MediaBrowser.ServerApplication/ApplicationHost.cs +++ b/MediaBrowser.ServerApplication/ApplicationHost.cs @@ -31,7 +31,6 @@ using MediaBrowser.Model.Logging; using MediaBrowser.Model.MediaInfo; using MediaBrowser.Model.System; using MediaBrowser.Model.Updates; -using MediaBrowser.Providers; using MediaBrowser.Providers.Manager; using MediaBrowser.Server.Implementations; using MediaBrowser.Server.Implementations.BdInfo; @@ -242,6 +241,52 @@ namespace MediaBrowser.ServerApplication LogManager.RemoveConsoleOutput(); } + public override Task Init(IProgress<double> progress) + { + DeleteDeprecatedModules(); + + return base.Init(progress); + } + + private void DeleteDeprecatedModules() + { + try + { + File.Delete(Path.Combine(ApplicationPaths.PluginsPath, "MBPhoto.dll")); + } + catch (IOException) + { + // Not there, no big deal + } + + try + { + Directory.Delete(Path.Combine(ApplicationPaths.DataPath, "remote-images"), true); + } + catch (IOException) + { + // Not there, no big deal + } + + try + { + Directory.Delete(Path.Combine(ApplicationPaths.DataPath, "extracted-video-images"), true); + } + catch (IOException) + { + // Not there, no big deal + } + + try + { + Directory.Delete(Path.Combine(ApplicationPaths.DataPath, "extracted-audio-images"), true); + } + catch (IOException) + { + // Not there, no big deal + } + } + /// <summary> /// Registers resources that classes will depend on /// </summary> |
