Skip to content

Commit

Permalink
fixed a bug when hardware detail would fail when there was no billing…
Browse files Browse the repository at this point in the history
… Item
  • Loading branch information
Christopher Gallo committed Oct 30, 2023
1 parent 35139b4 commit f00592d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion SoftLayer/CLI/hardware/detail.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def cli(env, identifier, passwords, price, components):
operating_system = utils.lookup(result, 'operatingSystem', 'softwareLicense', 'softwareDescription') or {}
memory = formatting.gb(result.get('memoryCapacity', 0))
owner = None
if utils.lookup(result, 'billingItem') != []:
if utils.lookup(result, 'billingItem'):
owner = utils.lookup(result, 'billingItem', 'orderItem', 'order', 'userRecord', 'username')

table_hard_drives = formatting.Table(['Name', 'Capacity', 'Serial #'])
Expand Down

0 comments on commit f00592d

Please sign in to comment.