Commit f99c6e6
authored
fix[stac_fastapi.core]: await request.body() coroutine (#551)
**Related Issue(s):**
N/A
**Description:**
Fixes an unawaited coroutine:
```
stac_fastapi/core/core.py:762: RuntimeWarning: coroutine 'Request.body' was never awaited
if request.method == "POST" and request.body():
```
`request.body()` always had a bool value of `True` as it is the
coroutine, not the result.
**PR Checklist:**
- [x] Code is formatted and linted (run `pre-commit run --all-files`)
- [x] Tests pass (run `make test`)
- [ ] Documentation has been updated to reflect changes, if applicable
- [x] Changes are added to the changelog1 parent d318e59 commit f99c6e6
2 files changed
+3
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
| 17 | + | |
16 | 18 | | |
17 | 19 | | |
18 | 20 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
759 | 759 | | |
760 | 760 | | |
761 | 761 | | |
762 | | - | |
| 762 | + | |
763 | 763 | | |
764 | 764 | | |
765 | 765 | | |
| |||
0 commit comments