Skip to content

Commit

Permalink
🚚 :: [#1237] playWithYoutubeMusic -> SongPlayPlatform
Browse files Browse the repository at this point in the history
  • Loading branch information
baekteun committed Aug 26, 2024
1 parent 8b8ac97 commit e3ea1a7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public final class PreferenceManager {
case ignoredPopupIDs // 다시보지 않는 팝업 IDs
case readNoticeIDs // 이미 읽은 공지 IDs
case pushNotificationAuthorizationStatus // 기기알림 on/off 상태
case playWithYoutubeMusic // 유튜브뮤직으로 재생할지 여부
case songPlayPlatformType // 유튜브뮤직으로 재생할지 여부
}

@UserDefaultWrapper(key: Constants.recentRecords.rawValue, defaultValue: nil)
Expand All @@ -46,7 +46,7 @@ public final class PreferenceManager {
@UserDefaultWrapper(key: Constants.pushNotificationAuthorizationStatus.rawValue, defaultValue: nil)
public static var pushNotificationAuthorizationStatus: Bool?

@UserDefaultWrapper(key: Constants.playWithYoutubeMusic.rawValue, defaultValue: YoutubePlayType.youtube)
@UserDefaultWrapper(key: Constants.songPlayPlatformType.rawValue, defaultValue: YoutubePlayType.youtube)
public static var songPlayPlatformType: YoutubePlayType?
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public struct WakmusicYoutubePlayer: WakmusicPlayer {
private let youtubeURLGenerator: any YoutubeURLGeneratable
private let ids: [String]
private var openerPlatform: OpenerPlatform {
let platform = PreferenceManager.playWithYoutubeMusic ?? .youtube
let platform = PreferenceManager.songPlayPlatformType ?? .youtube
switch platform {
case .youtube: return .youtube
case .youtubeMusic: return .youtubeMusic
Expand Down

0 comments on commit e3ea1a7

Please sign in to comment.