-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sync system notification settings; filter out Abacus notifications #258
Conversation
# Conflicts: # dydx/dydxPresenters/dydxPresenters.xcodeproj/project.pbxproj # dydx/dydxPresenters/dydxPresenters/_v4/GlobalWorkers/dydxGlobalWorkers.swift
# Conflicts: # dydx/dydxStateManager/dydxStateManager/AbacusStateManager.swift
if successful.boolValue { | ||
if let self = self { | ||
self.keyValueStore?.setValue(code, forKey: self._languageTag) | ||
let localizer = UIImplementations.shared?.localizer as? DynamicLocalizer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add some logging; no functional change
import RoutingKit | ||
import Utilities | ||
|
||
public final class dydxPushNotifcationToggleWorker: BaseWorker { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Notification*
viewModel?.cancelAction = { | ||
Router.shared?.navigate(to: RoutingRequest(path: "/action/dismiss", params: nil), animated: true, completion: nil) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🙏
@@ -57,7 +65,10 @@ private class dydxNotificationsSettingsViewPresenter: SettingsViewPresenter { | |||
cancelTitle: DataLocalizer.shared?.localize(path: "APP.GENERAL.CANCEL", params: nil) ?? "Cancel" | |||
) | |||
} | |||
// sync the settings with the system permission | |||
reloadSettings() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would this get called while user is being prompted to turn on notifications? Does this have an effect?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah.. it gets called, which sets the value back... But when the system notification value changes, it will be synced again.
Description / Intuition
Various updates for push notifications:
Type of Change