Update API to have a sensible grouping of sig_refs rather than separate arrays of sig_refs, sig_refs_names and sig_refs_urls

This commit is contained in:
Ian Renton
2025-10-31 09:51:54 +00:00
parent 6c95e845a4
commit 0c5b5f2062
21 changed files with 93 additions and 93 deletions

View File

@@ -6,6 +6,7 @@ import requests
from core.constants import HTTP_HEADERS
from core.sig_utils import get_icon_for_sig
from data.sig_ref import SIGRef
from data.spot import Spot
from spotproviders.http_spot_provider import HTTPSpotProvider
@@ -53,8 +54,7 @@ class HEMA(HTTPSpotProvider):
mode=freq_mode_match.group(2).upper(),
comment=spotter_comment_match.group(2),
sig="HEMA",
sig_refs=[spot_items[3].upper()],
sig_refs_names=[spot_items[4]],
sig_refs=[SIGRef(id=spot_items[3].upper(), name=spot_items[4])],
icon=get_icon_for_sig("HEMA"),
time=datetime.strptime(spot_items[0], "%d/%m/%Y %H:%M").replace(tzinfo=pytz.UTC).timestamp(),
dx_latitude=float(spot_items[7]),