Merge branch 'master' into openid
Conflicts: app/controllers/user_controller.rb app/views/user/terms.html.erb test/fixtures/users.yml
This commit is contained in:
commit
832b96b75a
299 changed files with 19654 additions and 6456 deletions
|
@ -1,4 +1,9 @@
|
|||
module I18n
|
||||
original_verbosity = $VERBOSE
|
||||
$VERBOSE = nil
|
||||
INTERPOLATION_PATTERN = /\{\{(\w+)\}\}/
|
||||
$VERBOSE = original_verbosity
|
||||
|
||||
module Backend
|
||||
class Simple
|
||||
module Implementation
|
||||
|
|
9
config/initializers/memcached.rb
Normal file
9
config/initializers/memcached.rb
Normal file
|
@ -0,0 +1,9 @@
|
|||
if defined?(PhusionPassenger) and defined?(MEMCACHE_SERVERS)
|
||||
PhusionPassenger.on_event(:starting_worker_process) do |forked|
|
||||
if forked
|
||||
MEMCACHE = MEMCACHE.clone
|
||||
RAILS_CACHE = ActiveSupport::Cache::CompressedMemCacheStore.new(MEMCACHE)
|
||||
ActionController::Base.cache_store = RAILS_CACHE
|
||||
end
|
||||
end
|
||||
end
|
|
@ -1,7 +1,14 @@
|
|||
if defined?(ActiveRecord::ConnectionAdaptors::PostgreSQLAdaptor)
|
||||
if defined?(ActiveRecord::ConnectionAdapters::PostgreSQLAdapter)
|
||||
module ActiveRecord
|
||||
module ConnectionAdapters
|
||||
class PostgreSQLAdapter
|
||||
def supports_disable_referential_integrity?() #:nodoc:
|
||||
version = query("SHOW server_version")[0][0].split('.')
|
||||
(version[0].to_i >= 9 || (version[0].to_i == 8 && version[1].to_i >= 1)) ? true : false
|
||||
rescue
|
||||
return false
|
||||
end
|
||||
|
||||
def pk_and_sequence_for(table)
|
||||
# First try looking for a sequence with a dependency on the
|
||||
# given table's primary key.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue