Skip to content

Commit a26dfa1

Browse files
author
Tania Allard
committed
Fixed description for NASA API queries
1 parent a54da02 commit a26dfa1

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

session5/CFG_app/app.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -87,17 +87,21 @@ def spotify_search_app():
8787

8888
@app.route("/NASA")
8989
def NASA_handler():
90-
""" This will only take you to the NASA search page"""
90+
""" This will only take you to the NASA search page. This will be used to perform
91+
get requests on the NASA picture of the day API, Thee user will need to
92+
choose a date to find a picture. It seems only pictures from 1999 onwards
93+
can be queried"""
9194

9295
return render_template("NASA.html")
9396

9497

9598
@app.route("/NASA_search", methods = ['POST'])
9699
def NASA_search_app():
97-
"""When the search is submitted from the previous page,
98-
this function passes the form data to our python scripts
99-
and uses them to perform the query. It will then return the tweets
100-
and display them in /tweets_show"""
100+
"""Since we are using the Picture of the Day API
101+
(APOD) this function will query the API using the
102+
provided date. Once the request is completed
103+
the picture as well as the title and description
104+
will be displayed in the next page"""
101105
date = request.form['date']
102106
APOD = get_APOD(date)
103107

0 commit comments

Comments
 (0)