Skip to content
This repository has been archived by the owner on Sep 5, 2023. It is now read-only.

"Enable Notifications" and "Summarize Notifications" state is lost when exiting the application #72

Closed
petitcl opened this issue Oct 12, 2021 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@petitcl
Copy link
Contributor

petitcl commented Oct 12, 2021

Describe the bug
In the "Active Deals" screen, the state of "Enable Notifications" and "Summarize Notifications" checkboxes is lost when exiting the application. When opening the app, it is always set to "Enable Notifications" checked and "Summarize Notifications" unchecked.

To Reproduce
Steps to reproduce the behavior:

  1. Go to Active Deals screen
  2. Uncheck "Enable Notifications" and check "Summarize Notifications"
  3. Exit the application normally
  4. Re-open the applicatiom
  5. "Enable Notifications" is checked and "Summarize Notifications" is unchecked. It should have been the opposite: "Enable Notifications" unchecked and "Summarize Notifications" is checked

Expected behavior
The application should remember the state of "Enable Notifications" and "Summarize Notifications", even after restarting the application. I assume most users (including myself) expect these settings to be remembered, especially when they want to disable notifications.

Desktop :

  • OS: Windows 10
  • Version: 1.0.0

Additional context
I browsed the code and found out these 2 settings are saved in the 3commas slice, which is not saved on disk and hence re initialized at each startup. I see there is another slice, config that is saved on disk and seem more appropriate. I propose to move the settings from 3commas slice to config slice. I think that the settings should be independant of the profile: it could be confusing for a user with multiple profiles to see the state of the checkbox change depending on the profile.

I'm interested in taking care of this issue, if that's good for you !

@petitcl petitcl added the bug Something isn't working label Oct 12, 2021
@coltoneshaw
Copy link
Owner

Hey! Great observation and definitely should be improved!!

You're welcome to take it if you like. It should be saved to localStorage and pulled from there when the components load. If you check out some of the charts that have filters you'll see how the local storage function works! Let me know if you have any issues with it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants