Remove unecessary list-routes command

Since this was added, Flask now comes with a build in command to list
the routes, `flask routes`, so this is not needed.
This commit is contained in:
Katie Smith
2021-11-12 17:05:17 +00:00
parent 6d9f2c27d9
commit 250ce38cf2

View File

@@ -252,13 +252,6 @@ def fix_notification_statuses_not_in_sync():
result = db.session.execute(subq_hist).fetchall()
@notify_command(name='list-routes')
def list_routes():
"""List URLs of all application routes."""
for rule in sorted(current_app.url_map.iter_rules(), key=lambda r: r.rule):
print("{:10} {}".format(", ".join(rule.methods - set(['OPTIONS', 'HEAD'])), rule.rule))
@notify_command(name='insert-inbound-numbers')
@click.option('-f', '--file_name', required=True,
help="""Full path of the file to upload, file is a contains inbound numbers,