Skip to content

Commit

Permalink
Moved log output to correct scope for used const
Browse files Browse the repository at this point in the history
Signed-off-by: jayonthenet <jay@humanitec.com>
  • Loading branch information
jayonthenet committed Oct 9, 2023
1 parent c183d20 commit 31c919e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/with-backstage/create-gh-app/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,8 @@ const writeConfigFile = async (data, webhookUrl) => {
}, null, 2)

await fs.writeFile(fileName, content);

console.log(`Created ${fileName}, you can close the server now.`)
}

const handleCallback = async (req, res) => {
Expand All @@ -109,8 +111,6 @@ const handleCallback = async (req, res) => {

await writeConfigFile(data, webhookUrl);

console.log(`Created ${fileName}, you can close the server now.`)

res.writeHead(302, { Location: `${data.html_url}/installations/new` });
res.end();
}
Expand Down

0 comments on commit 31c919e

Please sign in to comment.