Skip to content

Commit

Permalink
fix: default to youtube API by default
Browse files Browse the repository at this point in the history
  • Loading branch information
KRTirtho committed Aug 18, 2023
1 parent f90e9be commit 5a8a1e4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions lib/collections/language_codes.dart
Original file line number Diff line number Diff line change
Expand Up @@ -512,10 +512,10 @@ abstract class LanguageLocals {
// name: "Persian",
// nativeName: "فارسی",
// ),
// "pl": const ISOLanguageName(
// name: "Polish",
// nativeName: "polski",
// ),
"pl": const ISOLanguageName(
name: "Polish",
nativeName: "polski",
),
// "ps": const ISOLanguageName(
// name: "Pashto, Pushto",
// nativeName: "پښتو",
Expand Down
8 changes: 4 additions & 4 deletions lib/provider/user_preferences_provider.dart
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@ class UserPreferences extends PersistedChangeNotifier {
this.showSystemTrayIcon = true,
this.locale = const Locale("system", "system"),
this.pipedInstance = "https://pipedapi.kavin.rocks",
this.searchMode = SearchMode.youtubeMusic,
this.searchMode = SearchMode.youtube,
this.skipNonMusic = true,
this.youtubeApiType = YoutubeApiType.piped,
this.youtubeApiType = YoutubeApiType.youtube,
}) : super() {
if (downloadLocation.isEmpty && !kIsWeb) {
_getDefaultDownloadDirectory().then(
Expand Down Expand Up @@ -248,14 +248,14 @@ class UserPreferences extends PersistedChangeNotifier {

searchMode = SearchMode.values.firstWhere(
(mode) => mode.name == map["searchMode"],
orElse: () => SearchMode.youtubeMusic,
orElse: () => SearchMode.youtube,
);

skipNonMusic = map["skipNonMusic"] ?? skipNonMusic;

youtubeApiType = YoutubeApiType.values.firstWhere(
(type) => type.name == map["youtubeApiType"],
orElse: () => YoutubeApiType.piped,
orElse: () => YoutubeApiType.youtube,
);
}

Expand Down

0 comments on commit 5a8a1e4

Please sign in to comment.