allow admin users to get Splashscreen even when disabled (#13825)
Some checks failed
OpenAPI / OpenAPI - BASE (push) Waiting to run
OpenAPI / OpenAPI - HEAD (push) Waiting to run
OpenAPI / OpenAPI - Difference (push) Blocked by required conditions
OpenAPI / OpenAPI - Publish Unstable Spec (push) Blocked by required conditions
OpenAPI / OpenAPI - Publish Stable Spec (push) Blocked by required conditions
Tests / run-tests (macos-latest) (push) Waiting to run
Tests / run-tests (ubuntu-latest) (push) Waiting to run
Tests / run-tests (windows-latest) (push) Waiting to run
Project Automation / Project board (push) Waiting to run
Merge Conflict Labeler / Labeling (push) Waiting to run
CodeQL / Analyze (csharp) (push) Has been cancelled

refactor
This commit is contained in:
KGT1
2025-04-03 00:32:53 +02:00
committed by GitHub
parent 767ee2b5c4
commit 9c7cf808aa

View File

@@ -1727,7 +1727,8 @@ public class ImageController : BaseJellyfinApiController
[FromQuery, Range(0, 100)] int quality = 90)
{
var brandingOptions = _serverConfigurationManager.GetConfiguration<BrandingOptions>("branding");
if (!brandingOptions.SplashscreenEnabled)
var isAdmin = User.IsInRole(Constants.UserRoles.Administrator);
if (!brandingOptions.SplashscreenEnabled && !isAdmin)
{
return NotFound();
}