Skip to content

Commit

Permalink
prettier & fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
tjholm committed May 9, 2023
1 parent 89e6437 commit fc64dcb
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 18 deletions.
11 changes: 5 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,20 @@
</p>

<p align="center">
Build <a href="https://nitric.io">nitric</a> applications with Node.js
Build <a href="https://nitric.io">Nitric</a> applications with Node.js
</p>

<p align="center">
<img alt="Tests" src="https://github.com/nitrictech/node-sdk/actions/workflows/test.yaml/badge.svg?branch=main">
<a href="https://codecov.io/gh/nitrictech/node-sdk">
<img alt="codecov" src="https://codecov.io/gh/nitrictech/node-sdk/branch/main/graph/badge.svg?token=N46TTGPE4G">
<img alt="codecov" src="https://img.shields.io/codecov/c/github/nitrictech/node-sdk?style=for-the-badge">
</a>
<a href="https://npmjs.org/package/@nitric/sdk">
<img alt="Version" src="https://img.shields.io/npm/v/@nitric/sdk.svg">
<img alt="Version" src="https://img.shields.io/npm/v/@nitric/sdk.svg?style=for-the-badge">
</a>
<a href="https://npmjs.org/package/@nitric/sdk">
<img alt="Downloads/week" src="https://img.shields.io/npm/dw/@nitric/sdk.svg">
<img alt="Downloads/week" src="https://img.shields.io/npm/dw/@nitric/sdk.svg?style=for-the-badge">
</a>
<a href="https://discord.gg/Webemece5C"><img alt="Discord" src="https://img.shields.io/discord/955259353043173427?label=discord"></a>
<a href="https://discord.gg/Webemece5C"><img alt="Discord" src="https://img.shields.io/discord/955259353043173427?label=discord&style=for-the-badge"></a>
</p>

The NodeJS SDK supports the use of the Nitric framework with NodeJS 12+. For more information, check out the main [Nitric repo](https://github.com/nitrictech/nitric).
Expand Down
19 changes: 8 additions & 11 deletions assets/nitric-logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion src/faas/v0/context.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,11 +119,12 @@ export abstract class AbstractRequest<

/**
* Deserialize the request payload from JSON
*
*
* @returns JSON parsed request body
*/
json(): JSONT {
// attempt to deserialize as a JSON object
const textBody = this.text();
return textBody ? JSON.parse(textBody) : undefined;
}
}
Expand Down

0 comments on commit fc64dcb

Please sign in to comment.