Skip to content

Commit

Permalink
fix lint.
Browse files Browse the repository at this point in the history
  • Loading branch information
wparad committed Nov 27, 2024
1 parent b1f78c3 commit 066d2e9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/dynamoDbSafe.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ class DynamoDB extends DynamoDbOriginal.DocumentClient {
// Do not log items that are too bit, it will just become a huge problem for the caller.
const loggedParameters = error.code === 'ValidationException' && error.message === 'Item size has exceeded the maximum allowed size'
? { calculatedItemSize: JSON.stringify(originalParams).length }
: originalParams
: originalParams;

const wrappedError = new DynamoDbError({ message: error.message, method: 'Put', parameters: loggedParameters, dynamoDbStack: error.stack }, error.code);
wrappedError.stack = capturedStack;
Expand Down Expand Up @@ -167,7 +167,7 @@ class DynamoDB extends DynamoDbOriginal.DocumentClient {
// Do not log items that are too bit, it will just become a huge problem for the caller.
const loggedParameters = error.code === 'ValidationException' && error.message === 'Item size has exceeded the maximum allowed size'
? { calculatedItemSize: JSON.stringify(originalParams).length }
: originalParams
: originalParams;

const wrappedError = new DynamoDbError({ message: error.message, method: 'Update', parameters: loggedParameters, dynamoDbStack: error.stack }, error.code);
wrappedError.stack = capturedStack;
Expand Down

0 comments on commit 066d2e9

Please sign in to comment.