mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-30 05:46:30 +01:00
update recording file name
This commit is contained in:
@@ -385,8 +385,7 @@ namespace MediaBrowser.Server.Startup.Common
|
||||
new OmdbEpisodeProviderMigration(ServerConfigurationManager),
|
||||
new MovieDbEpisodeProviderMigration(ServerConfigurationManager),
|
||||
new DbMigration(ServerConfigurationManager, TaskManager),
|
||||
new UpdateLevelMigration(ServerConfigurationManager, this, HttpClient, JsonSerializer, _releaseAssetFilename),
|
||||
new CollectionsViewMigration(ServerConfigurationManager, UserManager)
|
||||
new UpdateLevelMigration(ServerConfigurationManager, this, HttpClient, JsonSerializer, _releaseAssetFilename)
|
||||
};
|
||||
|
||||
foreach (var task in migrations)
|
||||
|
||||
@@ -70,7 +70,6 @@
|
||||
<Compile Include="FFMpeg\FFMpegInfo.cs" />
|
||||
<Compile Include="INativeApp.cs" />
|
||||
<Compile Include="MbLinkShortcutHandler.cs" />
|
||||
<Compile Include="Migrations\CollectionsViewMigration.cs" />
|
||||
<Compile Include="Migrations\IVersionMigration.cs" />
|
||||
<Compile Include="Migrations\DbMigration.cs" />
|
||||
<Compile Include="Migrations\MovieDbEpisodeProviderMigration.cs" />
|
||||
|
||||
@@ -1,40 +0,0 @@
|
||||
using System.Linq;
|
||||
using MediaBrowser.Controller.Configuration;
|
||||
using MediaBrowser.Controller.Library;
|
||||
|
||||
namespace MediaBrowser.Server.Startup.Common.Migrations
|
||||
{
|
||||
public class CollectionsViewMigration : IVersionMigration
|
||||
{
|
||||
private readonly IServerConfigurationManager _config;
|
||||
private readonly IUserManager _userManager;
|
||||
|
||||
public CollectionsViewMigration(IServerConfigurationManager config, IUserManager userManager)
|
||||
{
|
||||
_config = config;
|
||||
_userManager = userManager;
|
||||
}
|
||||
|
||||
public void Run()
|
||||
{
|
||||
var migrationKey = this.GetType().Name;
|
||||
var migrationKeyList = _config.Configuration.Migrations.ToList();
|
||||
|
||||
if (!migrationKeyList.Contains(migrationKey))
|
||||
{
|
||||
if (_config.Configuration.IsStartupWizardCompleted)
|
||||
{
|
||||
if (_userManager.Users.Any(i => i.Configuration.DisplayCollectionsView))
|
||||
{
|
||||
_config.Configuration.DisplayCollectionsView = true;
|
||||
}
|
||||
}
|
||||
|
||||
migrationKeyList.Add(migrationKey);
|
||||
_config.Configuration.Migrations = migrationKeyList.ToArray();
|
||||
_config.SaveConfiguration();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user