Skip to content

Commit

Permalink
[fix] cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
lynnaloo committed Mar 29, 2017
1 parent 92631fd commit 1161d61
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
4 changes: 1 addition & 3 deletions aws-node-rekognition-analysis-s3-image/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ This example shows how to analys an image in an S3 bucket with Amazon Rekognitio

You need to create an S3 bucket and upload at least one file. Be sure the permissions on the folder and file allow public access and that CORS is configured to allow access.

Replace the values in `post.json` with the bucket and image name from S3.

```bash
npm install
```
Expand Down Expand Up @@ -50,7 +48,7 @@ functions:

You can now send an HTTP POST request directly to the endpoint using a tool like curl

```json
```
{
"bucket": "mycatphotos",
"imageName": "cat.jpg"
Expand Down
2 changes: 1 addition & 1 deletion aws-node-rekognition-analysis-s3-image/handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const ImageAnalyser = require('./lib/imageAnalyser');
Analyse an image on S3 using bucket and image name
*/
module.exports.imageAnalysis = (event, context, callback) => {
const data = event.body;
const data = JSON.parse(event.body);

const s3Config = {
bucket: data.bucket,
Expand Down
2 changes: 1 addition & 1 deletion aws-node-rekognition-analysis-s3-image/post.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"body": {
"bucket": "mycatphotos",
"imageName": "cat3.jpg"
"imageName": "cat.jpg"
}
}

0 comments on commit 1161d61

Please sign in to comment.