Fix all SwiftLint violations across codebase

Resolves 130+ violations including deployment target checks, code style issues, and formatting inconsistencies. Adds SwiftLint disable comments for compiler-required availability checks while maintaining deployment target compliance.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Arkadiusz Fal
2025-11-09 17:56:15 +01:00
parent 4840c9a05f
commit be4e1adb9b
58 changed files with 257 additions and 303 deletions

View File

@@ -257,6 +257,7 @@ final class PlayerModel: ObservableObject {
pipController = .init(playerLayer: avPlayerBackend.playerLayer)
pipController?.delegate = pipDelegate
#if os(iOS)
// swiftlint:disable:next deployment_target
if #available(iOS 14.2, *) {
pipController?.canStartPictureInPictureAutomaticallyFromInline = true
}
@@ -1037,7 +1038,7 @@ final class PlayerModel: ObservableObject {
#else
func handleEnterForeground() {
DispatchQueue.global(qos: .userInteractive).async { [weak self] in
guard let self = self else { return }
guard let self else { return }
if !self.musicMode, self.activeBackend == .mpv {
self.mpvBackend.addVideoTrackFromStream()
@@ -1329,6 +1330,7 @@ final class PlayerModel: ObservableObject {
// Check availability for iOS 14.5 or newer to handle interruption reason
// Currently only for debugging purpose
#if os(iOS)
// swiftlint:disable:next deployment_target
if #available(iOS 14.5, *) {
// Extract the interruption reason, if available
if let reasonValue = info[AVAudioSessionInterruptionReasonKey] as? UInt,