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: regression from #1123 #1554

Merged
merged 1 commit into from
Jul 31, 2018
Merged

Conversation

tech4him1
Copy link
Contributor

@tech4him1 tech4him1 commented Jul 30, 2018

- Summary

#1123 introduced a bug, where, instead of trimming the file extension with a preceding period from the end of a filename to get a slug, it trims the file extension plus one character, regardless of whether it was actually a period or not.

This is why we use linters!

- Test plan

- Description for the changelog

- A picture of a cute animal (not mandatory but encouraged)

Since we are building the regex with `new RegExp`, the escapes must be
double-escaped. Instead of `\.` to esape the period, we need `\\.`.
Because that was not done, we were simply checking for *any* character,
instead of a literal period.
@verythorough
Copy link
Contributor

Deploy preview for netlify-cms-www ready!

Built with commit 74f9429

https://deploy-preview-1554--netlify-cms-www.netlify.com

@verythorough
Copy link
Contributor

Deploy preview for cms-demo ready!

Built with commit 74f9429

https://deploy-preview-1554--cms-demo.netlify.com

@tech4him1 tech4him1 mentioned this pull request Jul 31, 2018
7 tasks
@erquhart erquhart merged commit 95c744e into decaporg:master Jul 31, 2018
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

3 participants