mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-11-15 18:08:53 -07:00
Added ServerName
This commit is contained in:
parent
4aaf10cb1e
commit
be36f1ef4c
@ -209,6 +209,8 @@ namespace MediaBrowser.Model.Configuration
|
||||
public bool EnableRealtimeMonitor { get; set; }
|
||||
public PathSubstitution[] PathSubstitutions { get; set; }
|
||||
|
||||
public string ServerName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="ServerConfiguration" /> class.
|
||||
/// </summary>
|
||||
|
@ -146,6 +146,12 @@ namespace MediaBrowser.Model.System
|
||||
/// <value><c>true</c> if [supports automatic run at startup]; otherwise, <c>false</c>.</value>
|
||||
public bool SupportsAutoRunAtStartup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the name of the server.
|
||||
/// </summary>
|
||||
/// <value>The name of the server.</value>
|
||||
public string ServerName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="SystemInfo" /> class.
|
||||
/// </summary>
|
||||
|
@ -336,6 +336,42 @@ namespace MediaBrowser.ServerApplication
|
||||
{
|
||||
// Not there, no big deal
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
Directory.Delete(Path.Combine(ApplicationPaths.DataPath, "fanart-movies"), true);
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
// Not there, no big deal
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
Directory.Delete(Path.Combine(ApplicationPaths.DataPath, "fanart-music"), true);
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
// Not there, no big deal
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
Directory.Delete(Path.Combine(ApplicationPaths.DataPath, "fanart-tv"), true);
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
// Not there, no big deal
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
Directory.Delete(Path.Combine(ApplicationPaths.DataPath, "tmdb-people"), true);
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
// Not there, no big deal
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@ -812,7 +848,8 @@ namespace MediaBrowser.ServerApplication
|
||||
HasUpdateAvailable = _hasUpdateAvailable,
|
||||
SupportsAutoRunAtStartup = SupportsAutoRunAtStartup,
|
||||
TranscodingTempPath = ApplicationPaths.TranscodingTempPath,
|
||||
IsRunningAsService = IsRunningAsService
|
||||
IsRunningAsService = IsRunningAsService,
|
||||
ServerName = string.IsNullOrWhiteSpace(ServerConfigurationManager.Configuration.ServerName) ? Environment.MachineName : ServerConfigurationManager.Configuration.ServerName
|
||||
};
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user