-
Notifications
You must be signed in to change notification settings - Fork 21.4k
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
extension synonyms yml and yaml #24318
Conversation
Thanks for the pull request, and welcome! The Rails team is excited to review your changes, and you should hear from @matthewd (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
The bot assigned this to someone else so unless you have a good reason to change please don't change it. As there is no reason to you assign it to me I'll revert it. |
@@ -21,7 +21,7 @@ | |||
Mime::Type.register "application/xml", :xml, %w( text/xml application/x-xml ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should .xml
extension likewise be registered?
also, perhaps refactor Mime::Type.register
API to use kwargs? (with deprecated current form)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.xml
extension is already registered no?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it is nevermind, just not clear from this line Mime::Type.register "application/xml", :xml, %w( text/xml application/x-xml )
as it's not passed as the extension argument.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you only need to pass the extension argument if you want to create aliases.
@matthewd, can be merged this pull request or i should close it? |
extension synonyms yml and yaml
Add extension synonyms
yml
andyaml
for MIME typeapplication/x-yaml
.