Skip to content

Commit

Permalink
debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
nothingalike committed Sep 27, 2020
1 parent 67286c2 commit 969b39c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ function execute() {
accessKeyId: AWS_ACCESS_KEY_ID,
secretAccessKey: AWS_SECRET_ACCESS_KEY
});

core.debug(MESSAGE);

const params = {
Message: MESSAGE,
Expand All @@ -24,13 +26,17 @@ function execute() {
const awsClient = new AWS.SNS({ apiVersion: "2010-03-31" });

awsClient.publish(params, function(err, data) {
if (err) core.setFailed(err.Message);
if (err) {
core.debug(err.Message);
core.setFailed(err.Message);
}
else {
core.debug("Published Topic Sent!");
return data.MessageId;
}
});
}catch(error) {
core.debug(err.Message);
core.setFailed(error.message);
}
}
Expand Down

0 comments on commit 969b39c

Please sign in to comment.