Skip to content

Commit

Permalink
Make more robust with validation function and string template
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Cresswell committed Oct 28, 2024
1 parent db8485c commit 572cce8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions components/data/ChannelData.bs
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import "pkg:/source/utils/config.bs"
sub setFields()
json = m.top.json
m.top.id = json.id
if json.number <> ""
m.top.title = json.number + " " + json.name
if isValid(json.number)
m.top.title = `CH ${json.number} ${json.name}`
else
m.top.title = json.name
end if
Expand Down

0 comments on commit 572cce8

Please sign in to comment.