def home(): if current_user.is_anonymous: page = request.args.get("page", 1, type=int) books = Books.get_paginated(page=page) return render_template("pages/home.html", form=SignupForm(request.form), books=books) else: return redirect(url_for("profile"))
def explore(): page = request.args.get("page", 1, type=int) books = Books.get_paginated(page=page) return render_template("pages/home.html", form=SignupForm(request.form), books=books)