Replace 'is' with '==' so the interpreter stops annoying me
This commit is contained in:
parent
526cfda6a8
commit
aa48b95652
@ -11,7 +11,7 @@ class SwapModule(AbstractModule):
|
|||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
|
|
||||||
actions = ["Create/Resize", "Delete", "Get location", "Get swap size"]
|
actions = ["Create/Resize", "Delete", "Get swap location", "Get swap size"]
|
||||||
menu = [
|
menu = [
|
||||||
{
|
{
|
||||||
'type': 'list',
|
'type': 'list',
|
||||||
@ -21,13 +21,13 @@ class SwapModule(AbstractModule):
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
selected_action = prompt(menu)['action']
|
selected_action = prompt(menu)['action']
|
||||||
if selected_action is "Create/Resize":
|
if selected_action == "Create/Resize":
|
||||||
self.create_resize_swap()
|
self.create_resize_swap()
|
||||||
elif selected_action is "Delete":
|
elif selected_action == "Delete":
|
||||||
self.delete_swap()
|
self.delete_swap()
|
||||||
elif selected_action is "Get location":
|
elif selected_action == "Get swap location":
|
||||||
self.swap_location_check()
|
self.swap_location_check()
|
||||||
elif selected_action is "Get swap size":
|
elif selected_action == "Get swap size":
|
||||||
self.get_swap_size()
|
self.get_swap_size()
|
||||||
|
|
||||||
def swap_location_check(self) -> None:
|
def swap_location_check(self) -> None:
|
||||||
|
Loading…
Reference in New Issue
Block a user