ag-common 0.0.751 → 0.0.752
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -20,7 +20,10 @@ const putDynamo = (item, tableName, opt) => __awaiter(void 0, void 0, void 0, fu
|
|
|
20
20
|
ConditionExpression: `attribute_not_exists(${opt.pkName})`,
|
|
21
21
|
}));
|
|
22
22
|
try {
|
|
23
|
-
yield (0, withRetry_1.withRetry)(() => _1.dynamoDb.send(new lib_dynamodb_1.PutCommand(putParams)), 'putDynamo');
|
|
23
|
+
const res = yield (0, withRetry_1.withRetry)(() => _1.dynamoDb.send(new lib_dynamodb_1.PutCommand(putParams)), 'putDynamo');
|
|
24
|
+
if (res.$metadata.httpStatusCode !== 200) {
|
|
25
|
+
return { error: res.toString() };
|
|
26
|
+
}
|
|
24
27
|
return { data: undefined };
|
|
25
28
|
}
|
|
26
29
|
catch (e) {
|
package/package.json
CHANGED