Skip to content

Commit

Permalink
more logs
Browse files Browse the repository at this point in the history
  • Loading branch information
bogdan-rosianu committed Feb 16, 2024
1 parent ce70d26 commit ece6338
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
4 changes: 3 additions & 1 deletion action/index.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -188021,6 +188021,8 @@ const robot = (app) => {
mainOwner = newOwners[0];
}
const extraOwners = newOwners.filter(x => !originalOwners.includes(x));
const printableFilenames = files.map(file => file.filename).join(', ');
console.log(`Names of changed files: ${printableFilenames}. original owners=${originalOwners}. new owners: ${newOwners}`);
const allOwners = [];
const allOwnersToCheck = [mainOwner, ...extraOwners];
let apiUrl = 'https://next-api.multiversx.com';
Expand Down Expand Up @@ -188072,7 +188074,7 @@ const robot = (app) => {
async function verify(body, address, message) {
const signature = /[0-9a-fA-F]{128}/.exec(body)?.at(0);
if (signature) {
const verifyResult = verifySignature(signature, address, message);
const verifyResult = await verifySignature(signature, address, message);
console.log(`verifying signature for address ${address}, message ${message}, and signature ${signature}. Result=${verifyResult}`);
return verifyResult;
}
Expand Down
5 changes: 4 additions & 1 deletion src/bot.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ export const robot = (app: Probot) => {

const extraOwners = newOwners.filter(x => !originalOwners.includes(x));

const printableFilenames = files.map(file => file.filename).join(', ');
console.log(`Names of changed files: ${printableFilenames}. original owners=${originalOwners}. new owners: ${newOwners}`);

const allOwners: string[] = [];
const allOwnersToCheck = [mainOwner, ...extraOwners];

Expand Down Expand Up @@ -118,7 +121,7 @@ export const robot = (app: Probot) => {
async function verify(body: string, address: string, message: string): Promise<boolean | undefined> {
const signature = /[0-9a-fA-F]{128}/.exec(body)?.at(0);
if (signature) {
const verifyResult = verifySignature(signature, address, message);
const verifyResult = await verifySignature(signature, address, message);
console.log(`verifying signature for address ${address}, message ${message}, and signature ${signature}. Result=${verifyResult}`);
return verifyResult;
}
Expand Down

0 comments on commit ece6338

Please sign in to comment.