Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Activerecord 1.9 compat #4343

Merged
merged 2 commits into from

2 participants

@carlosantoniodasilva

Revert 2 commits that were added for Ruby 1.8 compat.

@carlosantoniodasilva carlosantoniodasilva Revert "Add return for 1.8.7"
This reverts commit 665ef11.

There is no need for the return anymore, so reverting.
8c2e7bc
@carlosantoniodasilva carlosantoniodasilva Revert "Regexp.union seems to have different results in 1.8"
This reverts commit d80e4ee.

No need to care about 1.8 anymore, so reverting :)
a6a2670
@josevalim josevalim merged commit 291ad63 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jan 6, 2012
  1. @carlosantoniodasilva

    Revert "Add return for 1.8.7"

    carlosantoniodasilva authored
    This reverts commit 665ef11.
    
    There is no need for the return anymore, so reverting.
  2. @carlosantoniodasilva

    Revert "Regexp.union seems to have different results in 1.8"

    carlosantoniodasilva authored
    This reverts commit d80e4ee.
    
    No need to care about 1.8 anymore, so reverting :)
This page is out of date. Refresh to see the latest.
View
6 activerecord/test/cases/helper.rb
@@ -72,8 +72,8 @@ class SQLCounter
attr_reader :ignore
- def initialize(ignore = self.class.ignored_sql)
- @ignore = ignore
+ def initialize(ignore = Regexp.union(self.class.ignored_sql))
+ @ignore = ignore
end
def call(name, start, finish, message_id, values)
@@ -81,7 +81,7 @@ def call(name, start, finish, message_id, values)
# FIXME: this seems bad. we should probably have a better way to indicate
# the query was cached
- return if 'CACHE' == values[:name] || ignore.any? { |x| x =~ sql }
+ return if 'CACHE' == values[:name] || ignore =~ sql
self.class.log << sql
end
end
View
2  activerecord/test/cases/relation_scoping_test.rb
@@ -533,7 +533,7 @@ def test_default_scope_include_with_count
def test_default_scope_is_threadsafe
if in_memory_db?
- return skip "in memory db can't share a db between threads"
+ skip "in memory db can't share a db between threads"
end
threads = []
Something went wrong with that request. Please try again.