Skip to content
  • Piotr Sarnacki's avatar
    449a4fc0
    If partial is rendered in controller, grab format from template · 449a4fc0
    Piotr Sarnacki authored
    Previously `rendered_format` was set only based on mime types
    passed in Accept header, which was wrong if first type from
    Accept was different than rendered partial. The fix is to simply
    move setting rendered_format to the place where template
    is available and grab format from the template. If it fails
    we can fallback to formats passed by Accept header.
    449a4fc0
    If partial is rendered in controller, grab format from template
    Piotr Sarnacki authored
    Previously `rendered_format` was set only based on mime types
    passed in Accept header, which was wrong if first type from
    Accept was different than rendered partial. The fix is to simply
    move setting rendered_format to the place where template
    is available and grab format from the template. If it fails
    we can fallback to formats passed by Accept header.
Loading