[domain] changed "route" command to "domain", fixed "list_routes"

This commit is contained in:
Maxime Alves LIRMM@home 2020-08-05 21:26:59 +02:00
parent 914cb149e1
commit 63bd4c8db6
1 changed files with 3 additions and 3 deletions

View File

@ -28,7 +28,7 @@ def delete_domain(domain):
@click.option('--domain', '-d', default=None, multiple=True) @click.option('--domain', '-d', default=None, multiple=True)
@click.option('--update', default=False, is_flag=True) @click.option('--update', default=False, is_flag=True)
@cli.command() @cli.command()
def routes(domain, update): def domain(domain, update):
""" """
Lists routes for the specified domains, or update them in the database Lists routes for the specified domains, or update them in the database
@ -57,10 +57,10 @@ def routes(domain, update):
def list_routes(domain): def list_routes(domain):
click.echo(f'\nDomain {domain}') click.echo(f'\nDomain {domain} :')
routes = Acl(domain=domain) routes = Acl(domain=domain)
for route in routes.select(): for route in routes.select():
click.echo('-', route) click.echo(f'- {route}')
def update_db(domains): def update_db(domains):