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

fix: check if the comment exists or not before creating it. #22

Merged
merged 5 commits into from
Jul 16, 2021

Conversation

damcou
Copy link
Collaborator

@damcou damcou commented Jul 15, 2021

To prevent several messages to be created if a PR is edited, we search for the crawler Id (which is present in the link url) in the previous comments and we don't create another comment in such case.

@damcou damcou requested a review from bodinsamuel July 15, 2021 13:10
@netlify
Copy link

netlify bot commented Jul 15, 2021

✔️ Deploy Preview for algolia-ga-actions-netlify ready!

🔨 Explore the source changes: c8e6b14

🔍 Inspect the deploy log: https://app.netlify.com/sites/algolia-ga-actions-netlify/deploys/60f03f7fb2ccb70008a9c393

😎 Browse the preview: https://deploy-preview-22--algolia-ga-actions-netlify.netlify.app

@damcou
Copy link
Collaborator Author

damcou commented Jul 15, 2021

Copy link
Contributor

@bodinsamuel bodinsamuel left a comment

Choose a reason for hiding this comment

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

Looks good.

Can you try to push a commit to your Test PR to see if my comment triggers the early return?

Also, maybe the build should be done in the release script (but it's a topic for an other PR)

src/index.ts Outdated Show resolved Hide resolved
src/index.ts Show resolved Hide resolved
src/index.ts Show resolved Hide resolved
@damcou
Copy link
Collaborator Author

damcou commented Jul 15, 2021

Looks good.

Can you try to push a commit to your Test PR to see if my comment triggers the early return?

It didn't with the new user check

@damcou damcou requested a review from bodinsamuel July 15, 2021 14:27
@damcou damcou merged commit 3ba3f5b into main Jul 16, 2021
@damcou damcou deleted the fix/single-comment branch July 16, 2021 08:43
algolia-crawler-bot pushed a commit that referenced this pull request Jul 16, 2021
## [0.7.2](v0.7.1...v0.7.2) (2021-07-16)

### Bug Fixes

* check if the comment exists or not before creating it. ([#22](#22)) ([3ba3f5b](3ba3f5b))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants