mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-07-15 02:33:33 +01:00
Compare commits
16 Commits
renovate/s
...
renovate/m
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1a9bd2417a | ||
|
|
bc59e56ef5 | ||
|
|
cfeaef6180 | ||
|
|
ebab369eac | ||
|
|
0584a102ee | ||
|
|
2aae53bc15 | ||
|
|
911044b415 | ||
|
|
b77def6883 | ||
|
|
5c48935fa8 | ||
|
|
e2d9d592bc | ||
|
|
305160d2e4 | ||
|
|
933f7eea1b | ||
|
|
ed06fd5139 | ||
|
|
8bf1710e07 | ||
|
|
5e42941d3b | ||
|
|
9a2fdb3573 |
6
.github/workflows/ci-codeql-analysis.yml
vendored
6
.github/workflows/ci-codeql-analysis.yml
vendored
@@ -32,13 +32,13 @@ jobs:
|
||||
dotnet-version: '10.0.x'
|
||||
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@8aad20d150bbac5944a9f9d289da16a4b0d87c1e # v4.36.2
|
||||
uses: github/codeql-action/init@99df26d4f13ea111d4ec1a7dddef6063f76b97e9 # v4.37.0
|
||||
with:
|
||||
languages: ${{ matrix.language }}
|
||||
queries: +security-extended
|
||||
|
||||
- name: Autobuild
|
||||
uses: github/codeql-action/autobuild@8aad20d150bbac5944a9f9d289da16a4b0d87c1e # v4.36.2
|
||||
uses: github/codeql-action/autobuild@99df26d4f13ea111d4ec1a7dddef6063f76b97e9 # v4.37.0
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@8aad20d150bbac5944a9f9d289da16a4b0d87c1e # v4.36.2
|
||||
uses: github/codeql-action/analyze@99df26d4f13ea111d4ec1a7dddef6063f76b97e9 # v4.37.0
|
||||
|
||||
2
.github/workflows/issue-stale.yml
vendored
2
.github/workflows/issue-stale.yml
vendored
@@ -16,7 +16,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ contains(github.repository, 'jellyfin/') }}
|
||||
steps:
|
||||
- uses: actions/stale@eb5cf3af3ac0a1aa4c9c45633dd1ae542a27a899 # v10.3.0
|
||||
- uses: actions/stale@1e223db275d687790206a7acac4d1a11bd6fe629 # v10.4.0
|
||||
with:
|
||||
repo-token: ${{ secrets.JF_BOT_TOKEN }}
|
||||
ascending: true
|
||||
|
||||
2
.github/workflows/pull-request-stale.yaml
vendored
2
.github/workflows/pull-request-stale.yaml
vendored
@@ -15,7 +15,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ contains(github.repository, 'jellyfin/') }}
|
||||
steps:
|
||||
- uses: actions/stale@eb5cf3af3ac0a1aa4c9c45633dd1ae542a27a899 # v10.3.0
|
||||
- uses: actions/stale@1e223db275d687790206a7acac4d1a11bd6fe629 # v10.4.0
|
||||
with:
|
||||
repo-token: ${{ secrets.JF_BOT_TOKEN }}
|
||||
ascending: true
|
||||
|
||||
@@ -26,28 +26,28 @@
|
||||
<PackageVersion Include="libse" Version="4.0.12" />
|
||||
<PackageVersion Include="LrcParser" Version="2025.623.0" />
|
||||
<PackageVersion Include="MetaBrainz.MusicBrainz" Version="8.0.1" />
|
||||
<PackageVersion Include="Microsoft.AspNetCore.Authorization" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Testing" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.AspNetCore.Authorization" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Testing" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="5.6.0" />
|
||||
<PackageVersion Include="Microsoft.CodeAnalysis.Common" Version="5.6.0" />
|
||||
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp" Version="5.6.0" />
|
||||
<PackageVersion Include="Microsoft.CodeAnalysis.Analyzers" Version="5.6.0" />
|
||||
<PackageVersion Include="Microsoft.Data.Sqlite" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.EntityFrameworkCore.Design" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.EntityFrameworkCore.Relational" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.EntityFrameworkCore.Sqlite" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.EntityFrameworkCore.Tools" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Caching.Abstractions" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Caching.Memory" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Configuration.Abstractions" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Configuration.Binder" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Hosting.Abstractions" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Http" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Logging" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Options" Version="10.0.9" />
|
||||
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="18.7.0" />
|
||||
<PackageVersion Include="Microsoft.Data.Sqlite" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.EntityFrameworkCore.Design" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.EntityFrameworkCore.Relational" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.EntityFrameworkCore.Sqlite" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.EntityFrameworkCore.Tools" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Caching.Abstractions" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Caching.Memory" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Configuration.Abstractions" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Configuration.Binder" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Diagnostics.HealthChecks.EntityFrameworkCore" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Hosting.Abstractions" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Http" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Logging" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Options" Version="10.0.10" />
|
||||
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="18.8.1" />
|
||||
<PackageVersion Include="MimeTypes" Version="2.5.2" />
|
||||
<PackageVersion Include="Morestachio" Version="5.0.1.670" />
|
||||
<PackageVersion Include="Moq" Version="4.18.4" />
|
||||
@@ -74,10 +74,10 @@
|
||||
<PackageVersion Include="SkiaSharp.NativeAssets.Linux" Version="3.119.4" />
|
||||
<PackageVersion Include="SmartAnalyzers.MultithreadingAnalyzer" Version="1.1.31" />
|
||||
<PackageVersion Include="StyleCop.Analyzers" Version="1.2.0-beta.556" />
|
||||
<PackageVersion Include="Svg.Skia" Version="5.1.1" />
|
||||
<PackageVersion Include="Svg.Skia" Version="3.7.0" />
|
||||
<PackageVersion Include="Swashbuckle.AspNetCore.ReDoc" Version="10.2.3" />
|
||||
<PackageVersion Include="Swashbuckle.AspNetCore" Version="10.2.3" />
|
||||
<PackageVersion Include="System.Text.Json" Version="10.0.9" />
|
||||
<PackageVersion Include="System.Text.Json" Version="10.0.10" />
|
||||
<PackageVersion Include="TagLibSharp" Version="2.3.0" />
|
||||
<PackageVersion Include="z440.atl.core" Version="7.15.3" />
|
||||
<PackageVersion Include="TMDbLib" Version="3.0.0" />
|
||||
|
||||
@@ -106,5 +106,7 @@
|
||||
"TaskExtractMediaSegmentsDescription": "מחלץ חלקי מדיה מתוספים המאפשרים זאת.",
|
||||
"TaskMoveTrickplayImagesDescription": "הזזת קבצי Trickplay קיימים בהתאם להגדרות הספרייה.",
|
||||
"CleanupUserDataTaskDescription": "ניקוי כל המידע של המשתמש (מצב צפייה, מועדפים וכו) ממדיה שאינה קיימת מעל 90 יום.",
|
||||
"CleanupUserDataTask": "משימת ניקוי מידע משתמש"
|
||||
"CleanupUserDataTask": "משימת ניקוי מידע משתמש",
|
||||
"LyricDownloadFailureFromForItem": "הורדת המילים מ-{0} עבור {1} נכשלה",
|
||||
"Original": "מקור"
|
||||
}
|
||||
|
||||
@@ -385,7 +385,7 @@ namespace Emby.Server.Implementations.Localization
|
||||
|
||||
// Convert ints directly
|
||||
// This may override some of the locale specific age ratings (but those always map to the same age)
|
||||
if (int.TryParse(rating, out var ratingAge))
|
||||
if (TryParseRatingAsScore(rating, out var ratingAge))
|
||||
{
|
||||
return new(ratingAge, null);
|
||||
}
|
||||
@@ -487,6 +487,13 @@ namespace Emby.Server.Implementations.Localization
|
||||
return true;
|
||||
}
|
||||
|
||||
// If it's not a recognized rating string, fall back to using the number as the score
|
||||
if (TryParseRatingAsScore(ratingPart, out var numericScore))
|
||||
{
|
||||
result = new ParentalRatingScore(numericScore, null);
|
||||
return true;
|
||||
}
|
||||
|
||||
_logger.LogWarning(
|
||||
"Rating '{Rating}' not found in the '{CountryCode}' rating system, treating as unrated",
|
||||
rating,
|
||||
@@ -501,6 +508,18 @@ namespace Emby.Server.Implementations.Localization
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Tries to parse a rating as a number, allowing an optional trailing '+' (e.g. "16" or "18+").
|
||||
/// </summary>
|
||||
/// <param name="ratingValue">Rating value to parse.</param>
|
||||
/// <param name="score">Parsed score.</param>
|
||||
/// <returns>Returns true if parsing was successful.</returns>
|
||||
private static bool TryParseRatingAsScore(ReadOnlySpan<char> ratingValue, out int score)
|
||||
{
|
||||
var trimmed = ratingValue.TrimEnd('+');
|
||||
return int.TryParse(trimmed, out score);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public string GetLocalizedString(string phrase)
|
||||
{
|
||||
|
||||
@@ -10,21 +10,42 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"ratingStrings": ["K12"],
|
||||
"ratingStrings": ["K12", "K-12", "12"],
|
||||
"ratingScore": {
|
||||
"score": 12,
|
||||
"subScore": null
|
||||
}
|
||||
},
|
||||
{
|
||||
"ratingStrings": ["K13", "K-13", "13"],
|
||||
"ratingScore": {
|
||||
"score": 13,
|
||||
"subScore": null
|
||||
}
|
||||
},
|
||||
{
|
||||
"ratingStrings": ["K15"],
|
||||
"ratingStrings": ["K15", "K-15", "15"],
|
||||
"ratingScore": {
|
||||
"score": 15,
|
||||
"subScore": null
|
||||
}
|
||||
},
|
||||
{
|
||||
"ratingStrings": ["K18"],
|
||||
"ratingStrings": ["K16", "K-16", "16"],
|
||||
"ratingScore": {
|
||||
"score": 16,
|
||||
"subScore": null
|
||||
}
|
||||
},
|
||||
{
|
||||
"ratingStrings": ["K17", "K-17", "17"],
|
||||
"ratingScore": {
|
||||
"score": 17,
|
||||
"subScore": null
|
||||
}
|
||||
},
|
||||
{
|
||||
"ratingStrings": ["K18", "K-18", "18", "18+"],
|
||||
"ratingScore": {
|
||||
"score": 18,
|
||||
"subScore": null
|
||||
|
||||
@@ -492,8 +492,8 @@ namespace MediaBrowser.Controller.Entities
|
||||
public IOrderedEnumerable<Video> GetAdditionalParts(User user = null)
|
||||
{
|
||||
return GetAdditionalPartIds()
|
||||
.Select(i => LibraryManager.GetItemById<Video>(i, user))
|
||||
.Where(i => i is not null)
|
||||
.Select(i => LibraryManager.GetItemById<Video>(i))
|
||||
.Where(i => i is not null && (user is null || i.IsVisible(user)))
|
||||
.OrderBy(i => i.SortName);
|
||||
}
|
||||
|
||||
|
||||
@@ -84,7 +84,7 @@ namespace MediaBrowser.LocalMetadata.Images
|
||||
if (item.SupportsLocalMetadata)
|
||||
{
|
||||
// Episode has its own provider
|
||||
if (item is Episode || item is Audio || item is Photo)
|
||||
if (item is Episode || (item is Audio && item is not AudioBook) || item is Photo)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -167,7 +167,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
{
|
||||
if (fileInfo.Protocol == MediaProtocol.Http)
|
||||
{
|
||||
var result = await DetectCharset(fileInfo.Path, fileInfo.Protocol, cancellationToken).ConfigureAwait(false);
|
||||
var result = await DetectCharset(fileInfo.Path, cancellationToken).ConfigureAwait(false);
|
||||
var detected = result.Detected;
|
||||
|
||||
if (detected is not null)
|
||||
@@ -1104,7 +1104,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
}
|
||||
}
|
||||
|
||||
var result = await DetectCharset(path, mediaSource.Protocol, cancellationToken).ConfigureAwait(false);
|
||||
var result = await DetectCharset(path, cancellationToken).ConfigureAwait(false);
|
||||
var charset = result.Detected?.EncodingName ?? string.Empty;
|
||||
|
||||
// UTF16 is automatically converted to UTF8 by FFmpeg, do not specify a character encoding
|
||||
@@ -1120,8 +1120,9 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
return charset;
|
||||
}
|
||||
|
||||
private async Task<DetectionResult> DetectCharset(string path, MediaProtocol protocol, CancellationToken cancellationToken)
|
||||
private async Task<DetectionResult> DetectCharset(string path, CancellationToken cancellationToken)
|
||||
{
|
||||
var protocol = _mediaSourceManager.GetPathProtocol(path);
|
||||
switch (protocol)
|
||||
{
|
||||
case MediaProtocol.Http:
|
||||
@@ -1141,7 +1142,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles
|
||||
}
|
||||
|
||||
default:
|
||||
throw new ArgumentOutOfRangeException(nameof(protocol), protocol, "Unsupported protocol");
|
||||
throw new NotSupportedException($"Unsupported protocol: {protocol}");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -90,7 +90,7 @@ namespace MediaBrowser.Providers.Manager
|
||||
{
|
||||
ArgumentException.ThrowIfNullOrEmpty(mimeType);
|
||||
|
||||
var saveLocally = item.SupportsLocalMetadata && item.IsSaveLocalMetadataEnabled() && !item.ExtraType.HasValue && item is not Audio;
|
||||
var saveLocally = item.SupportsLocalMetadata && item.IsSaveLocalMetadataEnabled() && !item.ExtraType.HasValue && (item is AudioBook || item is not Audio);
|
||||
|
||||
if (type != ImageType.Primary && item is Episode)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user