Skip to content

Commit 9e42735

Browse files
authored
Update README.md
1 parent 1377701 commit 9e42735

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

.learn/exercises/07-post_todo/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ POST /todos
88
DELETE /todos
99
```
1010

11-
In order to build the `POST /todos` endpoint, we have to do something similar to what we did in the first endpoint with our GET method. Remember that each endpoint in a Flask API is represented by a function ( def my_function(): ) and a decorator ( @app.route() ) like this:
11+
In order to build the `POST /todos` endpoint, we have to do something similar to what we did in the first endpoint with our GET method. Remember that each endpoint in a Flask API is represented by decorator `@app.route()` and a function `def my_function():` like this:
1212

1313
```python
1414
@app.route('/myroute', methods=['GET'])
@@ -23,7 +23,7 @@ Also, we are expecting to receive the TODO that the client wants to add inside o
2323
```python
2424
from flask import request
2525

26-
# the request body is already json decoded and it comes in the request.json variable
26+
# The request body is already JSON decoded, and it comes in the request.json variable
2727
print(request.json)
2828
```
2929

@@ -35,7 +35,7 @@ print(request.json)
3535
from flask import request
3636
```
3737

38-
2. Then, Add the folowing endpoint to your app.py and test it:
38+
2. Then, add the following endpoint to your app.py and test it:
3939

4040
```python
4141
@app.route('/todos', methods=['POST'])

0 commit comments

Comments
 (0)