rails-timeago 1.1.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/rails-timeago/helper.rb +2 -3
- data/lib/rails-timeago/version.rb +1 -1
- data/spec/timeago_spec.rb +4 -0
- metadata +7 -7
data/lib/rails-timeago/helper.rb
CHANGED
@@ -37,10 +37,9 @@ module Rails
|
|
37
37
|
time_options = Rails::Timeago.default_options
|
38
38
|
|
39
39
|
time_options = time_options.merge html_options.extract!(*time_options.keys.select{|k| html_options.include?(k)})
|
40
|
-
html_options.merge! :title => I18n.l(time, :format => time_options[:format])
|
41
|
-
|
42
40
|
return time_options[:default] if time.nil?
|
43
|
-
|
41
|
+
|
42
|
+
html_options.merge! :title => I18n.l(time, :format => time_options[:format])
|
44
43
|
time_options[:limit] = time_options[:limit].call if time_options[:limit].is_a?(Proc)
|
45
44
|
|
46
45
|
if time_options[:force] or time_options[:limit].nil? or time_options[:limit] < time
|
data/spec/timeago_spec.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails-timeago
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -13,7 +13,7 @@ date: 2012-03-10 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|
16
|
-
requirement: &
|
16
|
+
requirement: &12945340 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '3.1'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *12945340
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: actionpack
|
27
|
-
requirement: &
|
27
|
+
requirement: &12944560 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: '3.1'
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *12944560
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: rspec
|
38
|
-
requirement: &
|
38
|
+
requirement: &12944120 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ! '>='
|
@@ -43,7 +43,7 @@ dependencies:
|
|
43
43
|
version: '0'
|
44
44
|
type: :development
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *12944120
|
47
47
|
description: jQuery Timeago helper for Rails 3
|
48
48
|
email:
|
49
49
|
- jan.graichen@altimos.de
|