mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
ensure callsign in correct format
This commit is contained in:
parent
97bc309bb6
commit
6829a9df85
1 changed files with 4 additions and 0 deletions
|
@ -1,9 +1,13 @@
|
|||
from command import TxCommand
|
||||
import api_validations
|
||||
|
||||
class PingCommand(TxCommand):
|
||||
|
||||
def set_params_from_api(self, apiParams):
|
||||
self.dxcall = apiParams['dxcall']
|
||||
if not api_validations.validate_freedata_callsign(self.dxcall):
|
||||
self.dxcall = f"{self.dxcall}-0"
|
||||
|
||||
return super().set_params_from_api(apiParams)
|
||||
|
||||
def build_frame(self):
|
||||
|
|
Loading…
Reference in a new issue