Skip to content
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

Json wifi structure update; password is saved on succesfull connection only #385

Merged
merged 1 commit into from
Nov 3, 2024

Conversation

Nolven
Copy link
Contributor

@Nolven Nolven commented Nov 3, 2024

What

  • wifi json field changed from
    wifi:[{s1:p1},{s2:p2}]
    to
    wifi:{s1:p1,s2:p2}
  • wifi password is now saved only upon successful connection

So refactoring + bug fixing + improvement

Why

O(1) instead of O(n) to find a wifi password
Code is cleaner
Bug fixed (:

Verification

Try to connect to a known wifi with the wrong password
Retry with the correct password
Disconnect from the wifi
Connect to it again. Check that the password type pop-up didn't appear and it used the stored password
(previously the password was saved on the first connection attempt rather than the successful one)

User-Facing Change

Users should clean the Wi-Fi section of the config file (or just remake the config file) otherwise the passwords won't be saved

password is stored only upon successful connection

Further Comments

This one is a preparation for a wifi repeater functionality

    wifi:[{s1:p1},{s2:p2}]
   to
    wifi:{s1:p1,s2:p2}
- wifi password is now saved only upon succesfull connection
@Nolven Nolven changed the title Json wifi structure update; password save on succesfull connection only Json wifi structure update; password is saved on succesfull connection only Nov 3, 2024
@pr3y pr3y merged commit 3415c84 into pr3y:main Nov 3, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants