Fixing merge issue.

This commit is contained in:
Marat Fayzullin 2023-06-04 12:34:16 -04:00
parent c174cef20e
commit 42abee5bf6
1 changed files with 3 additions and 0 deletions

View File

@ -303,9 +303,12 @@ class OpenWebRxReceiverClient(OpenWebRxClient, SdrSourceEventClient):
magic = self.stack["magic_key"]
key = params["key"] if "key" in params else None
self.setSdr(profile[0])
# If source not locked, or no magic key, or it matches...
if not self.sdr.isLocked() or magic == "" or key == magic:
# Select a new profile
self.sdr.activateProfile(profile[1])
else:
# Force update back to the current profile
self.sdr.activateProfile(self.sdr.getProfileId(), force=True)
elif message["type"] == "setfrequency":
# If the magic key is set in the settings, only allow