Skip to content

Commit

Permalink
[ServiceName] protect against NoneType objects
Browse files Browse the repository at this point in the history
  • Loading branch information
Huevos committed Oct 12, 2023
1 parent d83b22d commit bb969e9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/python/Components/Converter/ServiceName.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,13 +94,13 @@ def getText(self):
orbpos = self.getOrbitalPos(service, info)
res_str = ""
for x in self.parts[1:]:
if x == "NUMBER" and num != '':
if x == "NUMBER" and num:
res_str = self.appendToStringWithSeparator(res_str, num)
if x == "NAME" and name != '':
if x == "NAME" and name:
res_str = self.appendToStringWithSeparator(res_str, name)
if x == "ORBPOS" and orbpos != '':
if x == "ORBPOS" and orbpos:
res_str = self.appendToStringWithSeparator(res_str, orbpos)
if x == "PROVIDER" and provider is not None and provider != '':
if x == "PROVIDER" and provider:
res_str = self.appendToStringWithSeparator(res_str, provider)
return res_str

Expand Down

0 comments on commit bb969e9

Please sign in to comment.