diff options
| author | Cody Robibero <cody@robibe.ro> | 2022-02-14 16:56:29 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-02-14 16:56:29 -0700 |
| commit | 4acab009632251656158e1e9ded68574f64be967 (patch) | |
| tree | c4464963787150381cfc7a8890115f8929395333 /Jellyfin.Server/Middleware/BaseUrlRedirectionMiddleware.cs | |
| parent | 94b5334da53d9a1c7c35f1b69882c72a4b08af93 (diff) | |
| parent | 3cb49d6df005df12c2d626bcdfc708c353855f8e (diff) | |
Merge pull request #7038 from Bond-009/serverdiscovery
Diffstat (limited to 'Jellyfin.Server/Middleware/BaseUrlRedirectionMiddleware.cs')
| -rw-r--r-- | Jellyfin.Server/Middleware/BaseUrlRedirectionMiddleware.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Jellyfin.Server/Middleware/BaseUrlRedirectionMiddleware.cs b/Jellyfin.Server/Middleware/BaseUrlRedirectionMiddleware.cs index 3e5982eed..e0c112d60 100644 --- a/Jellyfin.Server/Middleware/BaseUrlRedirectionMiddleware.cs +++ b/Jellyfin.Server/Middleware/BaseUrlRedirectionMiddleware.cs @@ -5,7 +5,7 @@ using MediaBrowser.Controller.Configuration; using Microsoft.AspNetCore.Http; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Logging; -using ConfigurationExtensions = MediaBrowser.Controller.Extensions.ConfigurationExtensions; +using static MediaBrowser.Controller.Extensions.ConfigurationExtensions; namespace Jellyfin.Server.Middleware { @@ -65,7 +65,7 @@ namespace Jellyfin.Server.Middleware { // Always redirect back to the default path if the base prefix is invalid, missing, or is the full path. _logger.LogDebug("Normalizing an URL at {LocalPath}", localPath); - httpContext.Response.Redirect(baseUrlPrefix + "/" + _configuration[ConfigurationExtensions.DefaultRedirectKey]); + httpContext.Response.Redirect(baseUrlPrefix + "/" + _configuration[DefaultRedirectKey]); return; } } @@ -74,7 +74,7 @@ namespace Jellyfin.Server.Middleware { // Always redirect back to the default path if root is requested. _logger.LogDebug("Normalizing an URL at {LocalPath}", localPath); - httpContext.Response.Redirect("/" + _configuration[ConfigurationExtensions.DefaultRedirectKey]); + httpContext.Response.Redirect("/" + _configuration[DefaultRedirectKey]); return; } |
