From 2624885eab11cd3447b55c04611c80692b422f11 Mon Sep 17 00:00:00 2001 From: toast-ts <96593068+toast-ts@users.noreply.github.com> Date: Thu, 2 Mar 2023 11:43:36 +1100 Subject: [PATCH] Temporarily do this then do full one later. --- src/commands/dev.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/commands/dev.ts b/src/commands/dev.ts index 9050d45..6789c6c 100644 --- a/src/commands/dev.ts +++ b/src/commands/dev.ts @@ -63,8 +63,8 @@ export default { update: async()=>{ var githubRepo = {owner: 'AnxietyisReal', repo: 'Daggerbot-TS', ref: 'HEAD'} const octokit = new Octokit({timeZone: 'Australia/NSW', userAgent: 'Daggerbot'}) - const fetchCommitMsg = await octokit.repos.getCommit(githubRepo).then(x=>x.data.commit.message); - const fetchCommitAuthor = await octokit.repos.getCommit(githubRepo).then(x=>x.data.commit.author.name); + const fetchCommitMsg = await octokit.repos.getCommit(githubRepo).then(x=>x.data.commit.message).catch(err=>{console.log(err); interaction.reply({content: 'Placeholder error for `fetchCommitMsg`', ephemeral: true})}); + const fetchCommitAuthor = await octokit.repos.getCommit(githubRepo).then(x=>x.data.commit.author.name).catch(err=>{console.log(err); interaction.reply({content: 'Placeholder error for `fetchCommitAuthor`', ephemeral: true})}); const clarkson = await interaction.reply({content: 'Pulling from repository...', fetchReply: true}); exec('git pull',(err:Error,stdout)=>{ if (err){