No longer resetting magic key on initial page load.

This commit is contained in:
Marat Fayzullin 2023-05-21 11:32:57 -04:00
parent 5ac51fc3cc
commit 4561cb9632
2 changed files with 4 additions and 2 deletions

View File

@ -209,6 +209,7 @@ DemodulatorPanel.prototype.stopDemodulator = function() {
}
DemodulatorPanel.prototype._apply = function(params) {
this.setMagicKey(params.magic_key);
if (params.secondary_mod) {
this.setMode(params.secondary_mod, params.mod)
} else {
@ -217,7 +218,6 @@ DemodulatorPanel.prototype._apply = function(params) {
this.getDemodulator().set_offset_frequency(params.offset_frequency);
this.getDemodulator().setSquelch(params.squelch_level);
this.updateButtons();
this.setMagicKey(params.magic_key);
};
DemodulatorPanel.prototype.setInitialParams = function(params) {

View File

@ -103,7 +103,9 @@ class GeneralSettingsController(SettingsFormController):
"magic_key",
"Magic key",
infotext="Enter a key the user has to supply to change center frequency."
+ " Leave empty if you do not want to protect frequency changes with a key.",
+ " Leave empty if you do not want to protect frequency changes with a key."
+ " When enabled, the key has to be added to receiver's URL after the hash"
+ " sign: http://my.receiver.com/#key=keyvalue.",
),
),
Section(