I've noticed strange behavior with boolean settings and the modal settings dialog. I use Flarum beta 15.
If a boolean settings was ever changed, the settings dialog will display as checked every time when the settings page is reloded and settings dialog is opened, regardless of what was saved before.
To reproduce:
Enable extension
Open Settings
Check a checkbox
Save
Reload
Open Settings
Uncheck the checkbox
Save
Reload (important!)
Open Settings
The Checkbox will stay checked.
Looking into the Database, is seems like so:
When loading settings, null = unchecked, 0 or 1 = checked
When saving settings: 0 = unchecked, 1 = checked
I've noticed strange behavior with boolean settings and the modal settings dialog. I use Flarum beta 15. If a boolean settings was ever changed, the settings dialog will display as checked every time when the settings page is reloded and settings dialog is opened, regardless of what was saved before.
To reproduce:
The Checkbox will stay checked.
Looking into the Database, is seems like so: When loading settings, null = unchecked, 0 or 1 = checked When saving settings: 0 = unchecked, 1 = checked