Skip to content

Commit

Permalink
fix: address feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
IvanStepanok committed Nov 20, 2024
1 parent e38a7de commit 723b45a
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Course/Course/Presentation/Unit/CourseUnitView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ public struct CourseUnitView: View {
textColor: Theme.Colors.white)
.transition(.move(edge: .bottom))
.onAppear {
DispatchQueue.main.asyncAfter(deadline: .now() + Theme.Timeout.snackbarMessageLongTimeout) {
doAfter(Theme.Timeout.snackbarMessageLongTimeout) {
alertMessage = nil
showAlert = false
}
Expand Down
4 changes: 2 additions & 2 deletions OpenEdX.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -907,7 +907,7 @@
CODE_SIGN_ENTITLEMENTS = OpenEdX/OpenEdX.entitlements;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_TEAM = L8PG7LC3Y3;
DEVELOPMENT_TEAM = "";
FULLSTORY_ENABLED = NO;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = OpenEdX/Info.plist;
Expand Down Expand Up @@ -999,7 +999,7 @@
CODE_SIGN_ENTITLEMENTS = OpenEdX/OpenEdX.entitlements;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_TEAM = L8PG7LC3Y3;
DEVELOPMENT_TEAM = "";
FULLSTORY_ENABLED = NO;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = OpenEdX/Info.plist;
Expand Down
6 changes: 2 additions & 4 deletions Profile/Profile/Presentation/Settings/SettingsViewModel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -135,11 +135,9 @@ public final class SettingsViewModel: ObservableObject {
return emailURL
}

func update(downloadQuality: DownloadQuality) {
func update(downloadQuality: DownloadQuality) async {
self.userSettings.downloadQuality = downloadQuality
Task {
await interactor.saveSettings(userSettings)
}
await interactor.saveSettings(userSettings)
}

@MainActor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,11 @@ public struct VideoSettingsView: View {
Button {
viewModel.router.showVideoDownloadQualityView(
downloadQuality: viewModel.userSettings.downloadQuality,
didSelect: viewModel.update(downloadQuality:),
didSelect: { quality in
Task {
await viewModel.update(downloadQuality: quality)
}
},
analytics: viewModel.coreAnalytics
)
} label: {
Expand Down

0 comments on commit 723b45a

Please sign in to comment.