Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add thumbs up reaction #78

Merged
merged 5 commits into from
Aug 11, 2022
Merged

Add thumbs up reaction #78

merged 5 commits into from
Aug 11, 2022

Conversation

jetersen
Copy link
Contributor

@jetersen jetersen commented Aug 10, 2022

  • Make sure you are opening from a topic/feature/bugfix branch (right side) and not your main branch!
  • Ensure that the pull request title represents the desired changelog entry
  • Please describe what you did
  • Link to relevant issues in GitHub or Jira
  • Link to relevant pull requests, esp. upstream and downstream changes
  • Ensure you have provided tests - that demonstrates feature works or fixes the issue

app/router.js Outdated
: await reportError(authToken, payload.issue.node_id, result.error);
await (result.enabled
? Promise.all([
addReaction(authToken, payload.issue.comment.node_id, "THUMBS_UP"),
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh wait we are adding a comment for each commands recognized.

Perhaps we just do thumbs up whether it is enabled or not to show that we received the command.

? await command.run(authToken)
: await reportError(authToken, payload.issue.node_id, result.error);
try {
await addReaction(authToken, payload.comment.node_id, "THUMBS_UP");
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you had an extra level of nesting here under issue which didn't exist.

Gave a nice excuse to add error handling though :)

@timja timja added the enhancement New feature or request label Aug 11, 2022
@timja timja changed the title add thumbs up reaction Add thumbs up reaction Aug 11, 2022
@timja timja merged commit ed38e72 into timja:main Aug 11, 2022
@jetersen jetersen deleted the thumbs_up branch August 11, 2022 06:15
@timja
Copy link
Owner

timja commented Aug 11, 2022

Changed it to not error if reaction failed in #79

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants