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 for multiple mime type in yml, when i adding multiple mime to yml… #24

Merged
merged 4 commits into from Mar 27, 2017

Conversation

ishannz
Copy link

@ishannz ishannz commented Mar 26, 2017

… file for a single extention e.g - svg, its not adding to array.

Ishan Jayamanne added 2 commits March 27, 2017 12:31
… file for a single extention e.g - svg, its not adding to array.
} else {
$expectedMimes[] = $knownMimes[$extension];
}
foreach(array() $knownMimes[$extension] as $mime){

Choose a reason for hiding this comment

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

try

$mimes = (array)$knownMimes[$extension];
foreach ($mimes as $mime) {
	// ....
}

@tractorcow
Copy link

Nice job!

@tractorcow tractorcow merged commit e755f5b into silverstripe:master Mar 27, 2017
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