Merge pull request #5 from Bapabooiee/master
Compatibility fixes for ruby-1.8
This commit is contained in:
@@ -23,7 +23,7 @@ module ApplicationHelper
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def time_tag(content = nil, time)
|
def time_tag(content, time)
|
||||||
zone = time.strftime("%z")
|
zone = time.strftime("%z")
|
||||||
datetime = time.strftime("%Y-%m-%dT%H:%M" + zone[0, 3] + ":" + zone[3, 2])
|
datetime = time.strftime("%Y-%m-%dT%H:%M" + zone[0, 3] + ":" + zone[3, 2])
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# Be sure to restart your server when you modify this file.
|
# Be sure to restart your server when you modify this file.
|
||||||
|
|
||||||
Danbooru::Application.config.session_store :cookie_store, key: '_danbooru_session'
|
Danbooru::Application.config.session_store :cookie_store, :key => '_danbooru_session'
|
||||||
|
|
||||||
# Use the database for sessions instead of the cookie-based default,
|
# Use the database for sessions instead of the cookie-based default,
|
||||||
# which shouldn't be used to store highly confidential information
|
# which shouldn't be used to store highly confidential information
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
# is enabled by default.
|
# is enabled by default.
|
||||||
|
|
||||||
# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
|
# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
|
||||||
ActionController::Base.wrap_parameters format: [:json]
|
ActionController::Base.wrap_parameters :format => [:json]
|
||||||
|
|
||||||
# Disable root element in JSON by default.
|
# Disable root element in JSON by default.
|
||||||
if defined?(ActiveRecord)
|
if defined?(ActiveRecord)
|
||||||
|
|||||||
Reference in New Issue
Block a user