mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
Remove redundant trigger('change') call in setFrequency
The frequency change event is already triggered conditionally when fromWaterfall=false, so the unconditional trigger on the first line was redundant and could cause the change handler to execute twice.
This commit is contained in:
@@ -6248,9 +6248,10 @@ function setFrequency(frequencyInKHz, fromWaterfall) {
|
||||
}
|
||||
|
||||
// Update frequency field with value in Hz
|
||||
$('#frequency').val(frequencyInKHz * 1000).trigger('change');
|
||||
$('#frequency').val(frequencyInKHz * 1000);
|
||||
|
||||
// Also trigger change event unless called from waterfall
|
||||
// Trigger change event to update calculated fields and unit display
|
||||
// Skip trigger when called from waterfall to prevent recursive updates
|
||||
if (!fromWaterfall) {
|
||||
$('#frequency').trigger('change');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user