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

Fixed bug in filename slug when file extension is uppercase #39

Merged

Conversation

joestrong
Copy link
Contributor

When uploading a file with an uppercase extension like "filename.JPG" the uploaded filename and slug end up named like "filenamejpg.jpg"

The getExtension method lowercases the extension, and the slug method can't str_replace the uppercase extension using the lowercase one.

@@ -13,4 +13,13 @@ public function it_should_return_slugged_name_with_extension()

$this->assertEquals($expected, $name);
}

/** @test */
public function it_should_return_slugged_name_when_uppercase_extension_provided()

Choose a reason for hiding this comment

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

Method name FileHelperTest::it_should_return_slugged_name_when_uppercase_extension_provided is not in camel caps format

@nWidart
Copy link
Member

nWidart commented Jun 2, 2016

Thank you! 👍

@nWidart nWidart merged commit 385cd27 into AsgardCms:master Jun 2, 2016
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.

3 participants