From af08a1193fb7be598f0a64d31956af9f94191b150bc5de9d2dc29e9d48efc2c7 Mon Sep 17 00:00:00 2001 From: n Date: Sun, 16 Feb 2025 17:12:25 -0600 Subject: [PATCH] yipe --- src/toastbin/app.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/toastbin/app.py b/src/toastbin/app.py index a94e59e..ab83c9a 100644 --- a/src/toastbin/app.py +++ b/src/toastbin/app.py @@ -1,4 +1,4 @@ -from flask import Flask, render_template +from flask import Flask, render_template, request import json import database @@ -21,6 +21,11 @@ def login(): @app.route("/register", methods=['GET', 'POST']) def register(): - return render_template('register.j2', instance=instance) + if request.method == "GET": + return render_template('register.j2', instance=instance) + if request.method == "POST": + data = request.form + print(str(data)) + return render_template('register.j2', instance=instance) app.run(debug=True, host="0.0.0.0")