fix: target Jellyfin 10.11 / net9.0
Server 10.11 moved PermissionKind to Jellyfin.Database.Implementations.Enums, SetPermission to a Jellyfin.Data extension, and ChangePassword now takes a user id. Plugin built against 10.10 failed to load silently. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -4,7 +4,8 @@ using System.Linq;
|
||||
using System.Text.Json;
|
||||
using System.Threading.Tasks;
|
||||
using IdentityModel.OidcClient;
|
||||
using Jellyfin.Data.Enums;
|
||||
using Jellyfin.Data;
|
||||
using Jellyfin.Database.Implementations.Enums;
|
||||
using Jellyfin.Plugin.OidcAuth.Configuration;
|
||||
using MediaBrowser.Controller.Authentication;
|
||||
using MediaBrowser.Controller.Library;
|
||||
@@ -126,7 +127,7 @@ public class OidcAuthController : ControllerBase
|
||||
// Without a password Jellyfin accepts a blank password for this user
|
||||
// from any client. Users can set their own later in the web profile.
|
||||
await _userManager.ChangePassword(
|
||||
user,
|
||||
user.Id,
|
||||
Convert.ToBase64String(System.Security.Cryptography.RandomNumberGenerator.GetBytes(32)))
|
||||
.ConfigureAwait(false);
|
||||
}
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<RootNamespace>Jellyfin.Plugin.OidcAuth</RootNamespace>
|
||||
<AssemblyVersion>1.0.0.0</AssemblyVersion>
|
||||
<FileVersion>1.0.0.0</FileVersion>
|
||||
<AssemblyVersion>1.0.1.0</AssemblyVersion>
|
||||
<FileVersion>1.0.1.0</FileVersion>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Jellyfin.Controller" Version="10.10.7" />
|
||||
<PackageReference Include="Jellyfin.Controller" Version="10.11.11" />
|
||||
<PackageReference Include="IdentityModel.OidcClient" Version="5.2.1" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user