mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-07-09 03:04:24 -04:00
Remove more self-update code
This commit is contained in:
parent
25253cf961
commit
7554f63551
@ -119,7 +119,6 @@ namespace Emby.Notifications
|
|||||||
|
|
||||||
private async void _appHost_HasUpdateAvailableChanged(object sender, EventArgs e)
|
private async void _appHost_HasUpdateAvailableChanged(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
// This notification is for users who can't auto-update (aka running as service)
|
|
||||||
if (!_appHost.HasUpdateAvailable)
|
if (!_appHost.HasUpdateAvailable)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
|
@ -197,16 +197,6 @@ namespace MediaBrowser.Api.ScheduledTasks
|
|||||||
throw new ResourceNotFoundException("Task not found");
|
throw new ResourceNotFoundException("Task not found");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (string.Equals(task.ScheduledTask.Key, "SystemUpdateTask", StringComparison.OrdinalIgnoreCase))
|
|
||||||
{
|
|
||||||
// This is a hack for now just to get the update application function to work when auto-update is disabled
|
|
||||||
if (!_config.Configuration.EnableAutoUpdate)
|
|
||||||
{
|
|
||||||
_config.Configuration.EnableAutoUpdate = true;
|
|
||||||
_config.SaveConfiguration();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
TaskManager.Execute(task, new TaskOptions());
|
TaskManager.Execute(task, new TaskOptions());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -238,16 +228,14 @@ namespace MediaBrowser.Api.ScheduledTasks
|
|||||||
// https://code.google.com/p/servicestack/source/browse/trunk/Common/ServiceStack.Text/ServiceStack.Text/Controller/PathInfo.cs
|
// https://code.google.com/p/servicestack/source/browse/trunk/Common/ServiceStack.Text/ServiceStack.Text/Controller/PathInfo.cs
|
||||||
var id = GetPathValue(1);
|
var id = GetPathValue(1);
|
||||||
|
|
||||||
var task = TaskManager.ScheduledTasks.FirstOrDefault(i => string.Equals(i.Id, id));
|
var task = TaskManager.ScheduledTasks.FirstOrDefault(i => string.Equals(i.Id, id, StringComparison.Ordinal));
|
||||||
|
|
||||||
if (task == null)
|
if (task == null)
|
||||||
{
|
{
|
||||||
throw new ResourceNotFoundException("Task not found");
|
throw new ResourceNotFoundException("Task not found");
|
||||||
}
|
}
|
||||||
|
|
||||||
var triggerInfos = request;
|
task.Triggers = request.ToArray();
|
||||||
|
|
||||||
task.Triggers = triggerInfos.ToArray();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,20 +7,6 @@ namespace MediaBrowser.Model.Configuration
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public class BaseApplicationConfiguration
|
public class BaseApplicationConfiguration
|
||||||
{
|
{
|
||||||
// TODO: @bond Remove?
|
|
||||||
/// <summary>
|
|
||||||
/// Gets or sets a value indicating whether [enable debug level logging].
|
|
||||||
/// </summary>
|
|
||||||
/// <value><c>true</c> if [enable debug level logging]; otherwise, <c>false</c>.</value>
|
|
||||||
public bool EnableDebugLevelLogging { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Enable automatically and silently updating of the application
|
|
||||||
/// </summary>
|
|
||||||
/// <value><c>true</c> if [enable auto update]; otherwise, <c>false</c>.</value>
|
|
||||||
public bool EnableAutoUpdate { get; set; }
|
|
||||||
|
|
||||||
// TODO: @bond Remove?
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The number of days we should retain log files
|
/// The number of days we should retain log files
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -44,7 +30,6 @@ namespace MediaBrowser.Model.Configuration
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public BaseApplicationConfiguration()
|
public BaseApplicationConfiguration()
|
||||||
{
|
{
|
||||||
EnableAutoUpdate = true;
|
|
||||||
LogFileRetentionDays = 3;
|
LogFileRetentionDays = 3;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user