activesupport 3.2.6 → 3.2.7.rc1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of activesupport might be problematic. Click here for more details.

@@ -1,3 +1,11 @@
1
+ ## Rails 3.2.7 (unreleased)
2
+
3
+ * Hash#fetch(fetch) is not the same as doing hash[key]
4
+ * adds a missing require [fixes #6896]
5
+ * make sure the inflection rules are loaded when cherry-picking active_support/core_ext/string/inflections.rb [fixes #6884]
6
+ * Merge pull request #6857 from rsutphin/as_core_ext_time_missing_require
7
+ * bump AS deprecation_horizon to 4.0
8
+
1
9
  ## Rails 3.2.6 (Jun 12, 2012)
2
10
 
3
11
  * No changes.
@@ -1,5 +1,7 @@
1
1
  require 'active_support/duration'
2
2
  require 'active_support/core_ext/time/conversions'
3
+ require 'active_support/time_with_zone'
4
+ require 'active_support/core_ext/time/zones'
3
5
 
4
6
  class Time
5
7
  COMMON_YEAR_DAYS_IN_MONTH = [nil, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31]
@@ -1,4 +1,3 @@
1
- require 'active_support/core_ext/time/calculations'
2
1
  require 'active_support/time_with_zone'
3
2
 
4
3
  class Time
@@ -9,10 +9,10 @@ module ActiveSupport
9
9
  # The version the deprecated behavior will be removed, by default.
10
10
  attr_accessor :deprecation_horizon
11
11
  end
12
- self.deprecation_horizon = '3.2'
12
+ self.deprecation_horizon = '4.0'
13
13
 
14
14
  # By default, warnings are not silenced and debugging is off.
15
15
  self.silenced = false
16
16
  self.debug = false
17
17
  end
18
- end
18
+ end
@@ -93,7 +93,17 @@ module ActiveSupport
93
93
  alias_method :has_key?, :key?
94
94
  alias_method :member?, :key?
95
95
 
96
- # Fetches the value for the specified key, same as doing hash[key]
96
+ # Same as <tt>Hash#fetch</tt> where the key passed as argument can be
97
+ # either a string or a symbol:
98
+ #
99
+ # counters = HashWithIndifferentAccess.new
100
+ # counters[:foo] = 1
101
+ #
102
+ # counters.fetch("foo") # => 1
103
+ # counters.fetch(:bar, 0) # => 0
104
+ # counters.fetch(:bar) {|key| 0} # => 0
105
+ # counters.fetch(:zoo) # => KeyError: key not found: "zoo"
106
+ #
97
107
  def fetch(key, *extras)
98
108
  super(convert_key(key), *extras)
99
109
  end
@@ -1,3 +1,5 @@
1
+ require 'active_support/inflector/inflections'
2
+
1
3
  module ActiveSupport
2
4
  Inflector.inflections do |inflect|
3
5
  inflect.plural(/$/, 's')
@@ -1,5 +1,7 @@
1
1
  module ActiveSupport
2
2
  module Inflector
3
+ extend self
4
+
3
5
  # A singleton instance of this class is yielded by Inflector.inflections, which can then be used to specify additional
4
6
  # inflection rules. Examples:
5
7
  #
@@ -1,4 +1,5 @@
1
1
  require 'active_support/inflector/inflections'
2
+ require 'active_support/inflections'
2
3
 
3
4
  module ActiveSupport
4
5
  # The Inflector transforms words from singular to plural, class names to table names, modularized class names to ones without,
@@ -2,8 +2,8 @@ module ActiveSupport
2
2
  module VERSION #:nodoc:
3
3
  MAJOR = 3
4
4
  MINOR = 2
5
- TINY = 6
6
- PRE = nil
5
+ TINY = 7
6
+ PRE = "rc1"
7
7
 
8
8
  STRING = [MAJOR, MINOR, TINY, PRE].compact.join('.')
9
9
  end
metadata CHANGED
@@ -1,13 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: activesupport
3
3
  version: !ruby/object:Gem::Version
4
- hash: 3
5
- prerelease:
4
+ hash: 3118045377
5
+ prerelease: 6
6
6
  segments:
7
7
  - 3
8
8
  - 2
9
- - 6
10
- version: 3.2.6
9
+ - 7
10
+ - rc
11
+ - 1
12
+ version: 3.2.7.rc1
11
13
  platform: ruby
12
14
  authors:
13
15
  - David Heinemeier Hansson
@@ -15,7 +17,7 @@ autorequire:
15
17
  bindir: bin
16
18
  cert_chain: []
17
19
 
18
- date: 2012-06-12 00:00:00 Z
20
+ date: 2012-07-23 00:00:00 Z
19
21
  dependencies:
20
22
  - !ruby/object:Gem::Dependency
21
23
  name: i18n
@@ -292,12 +294,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
292
294
  required_rubygems_version: !ruby/object:Gem::Requirement
293
295
  none: false
294
296
  requirements:
295
- - - ">="
297
+ - - ">"
296
298
  - !ruby/object:Gem::Version
297
- hash: 3
299
+ hash: 25
298
300
  segments:
299
- - 0
300
- version: "0"
301
+ - 1
302
+ - 3
303
+ - 1
304
+ version: 1.3.1
301
305
  requirements: []
302
306
 
303
307
  rubyforge_project: