Revision 69dadbe4 snf-cyclades-app/synnefo/api/management/commands/floating-ip-dettach.py
b/snf-cyclades-app/synnefo/api/management/commands/floating-ip-dettach.py | ||
---|---|---|
37 | 37 |
from synnefo.management.common import get_floating_ip_by_address |
38 | 38 |
from synnefo.logic import backend |
39 | 39 |
|
40 |
|
|
40 | 41 |
class Command(BaseCommand): |
41 | 42 |
can_import_settings = True |
42 | 43 |
output_transaction = True |
... | ... | |
44 | 45 |
help = "Dettach a floating IP from a VM or router" |
45 | 46 |
|
46 | 47 |
def handle(self, *args, **options): |
47 |
if not args or len(args)>1:
|
|
48 |
if not args or len(args) > 1:
|
|
48 | 49 |
raise CommandError("Command accepts exactly one argument") |
49 | 50 |
|
50 | 51 |
address = args[0] |
Also available in: Unified diff