Don't set content type to JSON by default

This commit is contained in:
Piotr Sarnacki 2013-07-16 19:30:16 +02:00
parent eb1ffaeb77
commit 8e1a855812

View File

@ -14,7 +14,6 @@ class Travis::Api::App
# TODO hmmm? # TODO hmmm?
before { flash.clear } before { flash.clear }
before { content_type :json }
error(ActiveRecord::RecordNotFound, Sinatra::NotFound) { not_found } error(ActiveRecord::RecordNotFound, Sinatra::NotFound) { not_found }
not_found { content_type =~ /json/ ? { 'file' => 'not found' } : 'file not found' } not_found { content_type =~ /json/ ? { 'file' => 'not found' } : 'file not found' }