aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Joseph <[email protected]>2018-02-03 12:54:33 +0000
committerGravatar GitHub <[email protected]>2018-02-03 12:54:33 +0000
commit759ce9501a2ba3818846d6d3faed07be684d28de (patch)
tree5be52a4a2307b7c0ecbde0f368c8bdc258f56b19
parentCreate basic page (diff)
parentwrap in if main condition (diff)
Merge pull request #1 from Inveracity/patch-1
wrap in if main condition
-rw-r--r--__main__.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/__main__.py b/__main__.py
index 91eeda75..c1a40ad6 100644
--- a/__main__.py
+++ b/__main__.py
@@ -12,4 +12,5 @@ app.secret_key = os.environ.get("WEBPAGE_SECRET_KEY")
def index():
return "Hello."
-app.run(port=int(os.environ.get("WEBPAGE_PORT")), debug=False)
+if __name__ == '__main__':
+ app.run(port=int(os.environ.get("WEBPAGE_PORT")), debug=False)