Skip to content
This repository has been archived by the owner on Jul 5, 2023. It is now read-only.

Commit

Permalink
Fix regression in Ruby 1.8.7
Browse files Browse the repository at this point in the history
Fixes #40
  • Loading branch information
bobthecow committed Oct 10, 2012
1 parent faebbbf commit a29a39e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.markdown
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## v2.1.1

* Fix #38 — JSON rendering weirdness with empty array properties.
* Fix #40 — Ruby 1.8.7 regression.


## v2.1
Expand Down
2 changes: 1 addition & 1 deletion genghis.rb
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,7 @@ def error_response(status, message)
@genghis_version = GENGHIS_VERSION
if request.xhr?
content_type :json
error(status, {error: message, status: status}.to_json)
error(status, {:error => message, :status => status}.to_json)
else
error(status, mustache('error.html.mustache'.intern))
end
Expand Down
2 changes: 1 addition & 1 deletion src/rb/genghis/server.rb
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def error_response(status, message)
@genghis_version = GENGHIS_VERSION
if request.xhr?
content_type :json
error(status, {error: message, status: status}.to_json)
error(status, {:error => message, :status => status}.to_json)
else
error(status, mustache('error.html.mustache'.intern))
end
Expand Down

0 comments on commit a29a39e

Please sign in to comment.