From 617ffedef6225048962a2f9528373644a16eaa08 Mon Sep 17 00:00:00 2001 From: qnblackcat Date: Wed, 24 Jan 2024 21:45:57 +0700 Subject: [PATCH] support YT 19.03.2+ --- Sources/uYouPlusSettings.xm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Sources/uYouPlusSettings.xm b/Sources/uYouPlusSettings.xm index 1291e07..5f98fc4 100644 --- a/Sources/uYouPlusSettings.xm +++ b/Sources/uYouPlusSettings.xm @@ -204,7 +204,10 @@ extern NSBundle *uYouPlusBundle(); SWITCH_ITEM2(LOC(@"YT_RE_EXPLORE"), LOC(@"YT_RE_EXPLORE_DESC"), @"reExplore_enabled"); SWITCH_ITEM(LOC(@"ENABLE_FLEX"), LOC(@"ENABLE_FLEX_DESC"), @"flex_enabled"); - [settingsViewController setSectionItems:sectionItems forCategory:uYouPlusSection title:@"uYouPlus" titleDescription:LOC(@"TITLE DESCRIPTION") headerHidden:YES]; + if ([settingsViewController respondsToSelector:@selector(setSectionItems:forCategory:title:icon:titleDescription:headerHidden:)]) + [settingsViewController setSectionItems:sectionItems forCategory:uYouPlusSection title:@"uYouPlus" icon:nil titleDescription:LOC(@"TITLE DESCRIPTION") headerHidden:YES]; + else + [settingsViewController setSectionItems:sectionItems forCategory:uYouPlusSection title:@"uYouPlus" titleDescription:LOC(@"TITLE DESCRIPTION") headerHidden:YES]; } - (void)updateSectionForCategory:(NSUInteger)category withEntry:(id)entry {