8000 Fix #1399 by GuilhemN · Pull Request #1400 · FriendsOfSymfony/FOSRestBundle · GitHub
[go: up one dir, main page]

Skip to content

Fix #1399 #1400

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

Merged
merged 1 commit into from
Mar 26, 2016
Merged

Fix #1399 #1400

merged 1 commit into from
Mar 26, 2016

Conversation

GuilhemN
Copy link
Member

Fix #1399

Should be merged in 2.0 (wrong target...)


if ($config['view']['mime_types']['enabled'] && !method_exists(Request::class, 'getMimeTypes')) {
$container->getDefinition('fos_rest.format_negotiator')->addArgument($config['view']['mime_types']['formats']);
}
Copy link
Member

Choose a reason for hiding this comment

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

Are you sure that this is not needed?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah the mime types are already registered by the mime type listener in the Request and the format negotiator fetch them from the request.

Copy link
Member

Choose a reason for hiding this comment

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

I see, so the fix basically is to call get getValue() instead of getType()?

Copy link
Member Author

Choose a reason for hiding this comment

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

That's a part of the fix, we also need symfony/symfony#18255 to be merged.

Copy link
Member Author

Choose a reason for hiding this comment

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

In fact this PR is useless as long as symfony/symfony#18255 is not merged.

8000

@xabbuh
Copy link
Member
xabbuh commented Mar 26, 2016

symfony/symfony#18255 was merged

@GuilhemN GuilhemN merged commit 1ddfefc into master Mar 26, 2016
@GuilhemN GuilhemN deleted the fix-1399 branch March 26, 2016 11:29
@lsmith77 lsmith77 removed the wip/poc label Mar 26, 2016
@GuilhemN
Copy link
Member Author

@xabbuh thank you, I forgot this PR...

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

Successfully merging this pull request may close these issues.

3 participants
0