moving main to init
adding simpler main function
This commit is contained in:
@@ -440,7 +440,7 @@ def admin_taxonomy():
|
||||
return render_template('admin/taxonomy.html', title='Taxonomy', regions=regions, keywords=keywords)
|
||||
|
||||
|
||||
def main():
|
||||
def init():
|
||||
"""Main function to run the Flask app."""
|
||||
# Ensure DB is initialized
|
||||
db_init()
|
||||
@@ -452,5 +452,9 @@ def main():
|
||||
app.run(debug=True, host='127.0.0.1', port=5000)
|
||||
|
||||
|
||||
def main():
|
||||
app.run()
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
||||
Reference in New Issue
Block a user