Skip to content

Commit

Permalink
Update retrieve-label-directory.js
Browse files Browse the repository at this point in the history
  • Loading branch information
t-will-gillis authored Oct 14, 2024
1 parent d0d9b59 commit bca2e5f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions github-actions/utils/retrieve-label-directory.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// Import module
const fs = require('fs');

// Global variables
Expand All @@ -18,10 +19,8 @@ function retrieveLabelName(labelKey) {
labelData = JSON.parse(rawData);
}

let labelName = '';

try {
labelName = labelData[labelKey][0];
const labelName = labelData[labelKey][0];
console.log(`Success! Found labelKey: '${labelKey}', returning labelName: '${labelName}'`);
} catch (err) {
console.error(`Failed to find labelKey: '${labelKey}'`)
Expand Down

0 comments on commit bca2e5f

Please sign in to comment.