From 421880aafda7f6b517b23fb5abb0a0c26186003d Mon Sep 17 00:00:00 2001 From: Andy Lindeman Date: Tue, 8 Apr 2014 14:47:09 -0400 Subject: [PATCH] Sets Content-Type for `jbuilder` responses Similar to --- lib/sinatra/jbuilder.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/sinatra/jbuilder.rb b/lib/sinatra/jbuilder.rb index 4284cc0..55608cc 100644 --- a/lib/sinatra/jbuilder.rb +++ b/lib/sinatra/jbuilder.rb @@ -4,6 +4,7 @@ module Sinatra module Templates def jbuilder(template, options={}, locals={}) + options[:default_content_type] = :json render :jbuilder, template, options, locals end