context_processors: prevent a null station error when no default station is defined
This commit is contained in:
parent
2751abcabc
commit
2f50476c47
|
@ -1,3 +1,4 @@
|
||||||
def station(request):
|
def station(request):
|
||||||
station = request.station
|
station = request.station
|
||||||
return {"station": station, "audio_streams": station.streams}
|
audio_streams = station.streams if station else None
|
||||||
|
return {"station": station, "audio_streams": audio_streams}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user