-
Notifications
You must be signed in to change notification settings - Fork 287
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(upload): return type on is now a string (#976)
* fix(upload): return type on POST is now string A POST to a webserver can not always be expected to be a JSON response. Success is now determined by the HTTP return code. Upon success the body content is returned as a string. * feat: add content-length on POST Not all embedded devices are acceptable to receiving unspecified amounts of data. Appending the content-length up front helps this devices succeed. * fix: return values unified The return values was not used. On POST the HTTP error code is returned as an enum. * fix: upload, return value as string * Update plugins/upload/src/lib.rs Co-authored-by: Lucas Fernandes Nogueira <[email protected]> * Update plugins/upload/src/lib.rs Co-authored-by: Lucas Fernandes Nogueira <[email protected]> * fix: added covector changelog file --------- Co-authored-by: Lucas Fernandes Nogueira <[email protected]>
- Loading branch information
1 parent
9144521
commit 4a5ab18
Showing
3 changed files
with
24 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"upload": patch | ||
"upload-js": patch | ||
--- | ||
|
||
Return the upload response as a string and error out if the status code is not within 200-299. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters