Skip to content

Commit

Permalink
Don't fail when "from_name" cannot be found (#111)
Browse files Browse the repository at this point in the history
  • Loading branch information
crazy-max committed Sep 28, 2020
1 parent eac344e commit 4e122e2
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 10 deletions.
5 changes: 5 additions & 0 deletions .res/labels.update.yml
Expand Up @@ -6,6 +6,11 @@
name: ":bug: bug"
color: "b60205"
description: ""
- # new bug
name: ":bug: new bug"
color: "b60205"
description: ""
from_name: "bug"
- # documentation
name: ":memo: documentation"
color: "c5def5"
Expand Down
2 changes: 1 addition & 1 deletion __tests__/labeler.test.ts
Expand Up @@ -14,7 +14,7 @@ const cases = [
{
skip: 13,
exclude: 0,
create: 0,
create: 1,
update: 2,
rename: 1,
delete: 3,
Expand Down
2 changes: 0 additions & 2 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 0 additions & 7 deletions src/labeler.ts
Expand Up @@ -244,13 +244,6 @@ export class Labeler {
});
continue;
}

labels.push({
...fileLabel,
ghaction_status: LabelStatus.Error,
ghaction_log: `❌ Label '${fileLabel.from_name}' not found. Cannot rename`
});
continue;
}

// Update
Expand Down

0 comments on commit 4e122e2

Please sign in to comment.