diff --git a/Extensions/NSTextField+FocusRingType.swift b/Extensions/NSTextField+FocusRingType.swift index 1fb58d54..603c5879 100644 --- a/Extensions/NSTextField+FocusRingType.swift +++ b/Extensions/NSTextField+FocusRingType.swift @@ -3,6 +3,6 @@ import AppKit extension NSTextField { override open var focusRingType: NSFocusRingType { get { .none } - set {} // swiftlint:disable:this unused_setter_value + set {} } } diff --git a/Shared/Player/PlaybackBar.swift b/Shared/Player/PlaybackBar.swift index 589f348c..e27e80cd 100644 --- a/Shared/Player/PlaybackBar.swift +++ b/Shared/Player/PlaybackBar.swift @@ -103,12 +103,13 @@ struct PlaybackBar: View { return "loading..." } - guard let video = player.currentVideo else { + guard let video = player.currentVideo, + let time = player.time else { return "" } let videoLengthAtRate = video.length / Double(player.currentRate) - let remainingSeconds = videoLengthAtRate - player.time!.seconds + let remainingSeconds = videoLengthAtRate - time.seconds if remainingSeconds < 60 { return "less than a minute"