mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-12-16 22:13:06 +03:00
Merge remote-tracking branch 'upstream/master' into api-migration
This commit is contained in:
@@ -53,14 +53,12 @@ namespace Jellyfin.Api.Controllers
|
||||
[ProducesResponseType(StatusCodes.Status200OK)]
|
||||
public ActionResult<StartupConfigurationDto> GetStartupConfiguration()
|
||||
{
|
||||
var result = new StartupConfigurationDto
|
||||
return new StartupConfigurationDto
|
||||
{
|
||||
UICulture = _config.Configuration.UICulture,
|
||||
MetadataCountryCode = _config.Configuration.MetadataCountryCode,
|
||||
PreferredMetadataLanguage = _config.Configuration.PreferredMetadataLanguage
|
||||
};
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -110,10 +108,10 @@ namespace Jellyfin.Api.Controllers
|
||||
[HttpGet("User")]
|
||||
[HttpGet("FirstUser")]
|
||||
[ProducesResponseType(StatusCodes.Status200OK)]
|
||||
public ActionResult<StartupUserDto> GetFirstUser()
|
||||
public async Task<StartupUserDto> GetFirstUser()
|
||||
{
|
||||
// TODO: Remove this method when startup wizard no longer requires an existing user.
|
||||
_userManager.Initialize();
|
||||
await _userManager.InitializeAsync().ConfigureAwait(false);
|
||||
var user = _userManager.Users.First();
|
||||
return new StartupUserDto
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user