Compare commits

...

2 Commits

Author SHA1 Message Date
semantic-release-bot
7bac023ea5 chore: Release v5.6.0-dev.4 [skip ci]
# [5.6.0-dev.4](https://github.com/ReVanced/revanced-patches/compare/v5.6.0-dev.3...v5.6.0-dev.4) (2024-12-20)

### Bug Fixes

* **YouTube - Force original audio:** Use correct original audio stream if app language is not English ([1d0ec98](1d0ec98bec))
2024-12-20 16:29:05 +00:00
LisoUseInAIKyrios
1d0ec98bec fix(YouTube - Force original audio): Use correct original audio stream if app language is not English 2024-12-20 20:26:17 +04:00
3 changed files with 11 additions and 4 deletions

View File

@@ -1,3 +1,10 @@
# [5.6.0-dev.4](https://github.com/ReVanced/revanced-patches/compare/v5.6.0-dev.3...v5.6.0-dev.4) (2024-12-20)
### Bug Fixes
* **YouTube - Force original audio:** Use correct original audio stream if app language is not English ([0d20171](https://github.com/ReVanced/revanced-patches/commit/0d2017133efac230887b5c2a331d87159df8af11))
# [5.6.0-dev.3](https://github.com/ReVanced/revanced-patches/compare/v5.6.0-dev.2...v5.6.0-dev.3) (2024-12-20) # [5.6.0-dev.3](https://github.com/ReVanced/revanced-patches/compare/v5.6.0-dev.2...v5.6.0-dev.3) (2024-12-20)

View File

@@ -6,7 +6,7 @@ import app.revanced.extension.youtube.settings.Settings;
@SuppressWarnings("unused") @SuppressWarnings("unused")
public class ForceOriginalAudioPatch { public class ForceOriginalAudioPatch {
private static final String DEFAULT_AUDIO_TRACKS_IDENTIFIER = "original"; private static final String DEFAULT_AUDIO_TRACKS_SUFFIX = ".4";
/** /**
* Injection point. * Injection point.
@@ -17,7 +17,7 @@ public class ForceOriginalAudioPatch {
return isDefault; return isDefault;
} }
if (audioTrackDisplayName.isEmpty()) { if (audioTrackId.isEmpty()) {
// Older app targets can have empty audio tracks and these might be placeholders. // Older app targets can have empty audio tracks and these might be placeholders.
// The real audio tracks are called after these. // The real audio tracks are called after these.
return isDefault; return isDefault;
@@ -26,7 +26,7 @@ public class ForceOriginalAudioPatch {
Logger.printDebug(() -> "default: " + String.format("%-5s", isDefault) + " id: " Logger.printDebug(() -> "default: " + String.format("%-5s", isDefault) + " id: "
+ String.format("%-8s", audioTrackId) + " name:" + audioTrackDisplayName); + String.format("%-8s", audioTrackId) + " name:" + audioTrackDisplayName);
final boolean isOriginal = audioTrackDisplayName.contains(DEFAULT_AUDIO_TRACKS_IDENTIFIER); final boolean isOriginal = audioTrackId.endsWith(DEFAULT_AUDIO_TRACKS_SUFFIX);
if (isOriginal) { if (isOriginal) {
Logger.printDebug(() -> "Using audio: " + audioTrackId); Logger.printDebug(() -> "Using audio: " + audioTrackId);
} }

View File

@@ -3,4 +3,4 @@ org.gradle.jvmargs = -Xms512M -Xmx2048M
org.gradle.parallel = true org.gradle.parallel = true
android.useAndroidX = true android.useAndroidX = true
kotlin.code.style = official kotlin.code.style = official
version = 5.6.0-dev.3 version = 5.6.0-dev.4