-
Notifications
You must be signed in to change notification settings - Fork 57
Expand file tree
/
Copy pathapp.py
More file actions
35 lines (25 loc) · 652 Bytes
/
app.py
File metadata and controls
35 lines (25 loc) · 652 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
from flask import Flask, render_template, request
import api
app = Flask('tinder-detective')
stalker = api.NSASimulator()
@app.route('/')
def index():
profiles = stalker.get_profiles()
return render_template("main.html", profiles=profiles)
@app.route('/like/')
def like():
user = request.args.get('user')
stalker.like(user)
return ''
@app.route('/superlike/')
def superlike():
user = request.args.get('user')
stalker.superlike(user)
return ''
@app.route('/pass/')
def pass_vote():
user = request.args.get('user')
stalker.pass_vote(user)
return ''
if __name__ == '__main__':
app.run(debug=True)