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: add newlines if they are missing #50

Merged
merged 4 commits into from
Jul 13, 2021
Merged

fix: add newlines if they are missing #50

merged 4 commits into from
Jul 13, 2021

Conversation

rethab
Copy link
Contributor

@rethab rethab commented Jul 12, 2021

when a private key is copied manually into the env variables on github, newlines might get missing altogether. this can lead to issues like auth0/node-jsonwebtoken#642

this change transparently adds newlines if they are missing

Copy link
Contributor

@gr2m gr2m left a comment

Choose a reason for hiding this comment

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

The change looks good, just one suggestion

src/index.ts Outdated Show resolved Hide resolved
rethab and others added 3 commits July 13, 2021 19:15
Co-authored-by: Gregor Martynus <39992+gr2m@users.noreply.github.com>
@rethab
Copy link
Contributor Author

rethab commented Jul 13, 2021

@gr2m committed your suggestion and added a test for it. I realised there's also a trim missing if there are spaces at the end of the "middle" part.

Copy link
Contributor

@gr2m gr2m left a comment

Choose a reason for hiding this comment

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

great PR, thank you!

@gr2m gr2m changed the title chore: add newlines if they are missing fix: add newlines if they are missing Jul 13, 2021
@gr2m gr2m merged commit 094fe45 into probot:main Jul 13, 2021
@github-actions
Copy link

🎉 This PR is included in version 1.1.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

2 participants