merit 1.2.2 → 1.2.3
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile.lock +1 -1
- data/lib/merit.rb +8 -7
- data/merit.gemspec +1 -1
- metadata +1 -1
data/Gemfile.lock
CHANGED
data/lib/merit.rb
CHANGED
@@ -50,16 +50,17 @@ module Merit
|
|
50
50
|
end
|
51
51
|
|
52
52
|
ActiveSupport.on_load(:action_controller) do
|
53
|
-
|
54
|
-
|
55
|
-
if defined? '::Merit::BadgeRules'
|
53
|
+
begin
|
54
|
+
# Load application defined rules on application boot up
|
56
55
|
::Merit::AppBadgeRules = ::Merit::BadgeRules.new.defined_rules
|
57
|
-
end
|
58
|
-
if defined? '::Merit::PointRules'
|
59
56
|
::Merit::AppPointRules = ::Merit::PointRules.new.defined_rules
|
57
|
+
include Merit::ControllerExtensions
|
58
|
+
rescue NameError => e
|
59
|
+
# Trap NameError if installing/generating files
|
60
|
+
if !(e.to_s =~ /uninitialized constant Merit::BadgeRules/)
|
61
|
+
raise e
|
62
|
+
end
|
60
63
|
end
|
61
|
-
|
62
|
-
include Merit::ControllerExtensions
|
63
64
|
end
|
64
65
|
end
|
65
66
|
end
|
data/merit.gemspec
CHANGED
@@ -4,7 +4,7 @@ Gem::Specification.new do |s|
|
|
4
4
|
s.description = "Manage badges, points and rankings (reputation) of resources in a Rails application."
|
5
5
|
s.homepage = "http://github.com/tute/merit"
|
6
6
|
s.files = `git ls-files`.split("\n").reject{|f| f =~ /^\./ }
|
7
|
-
s.version = '1.2.
|
7
|
+
s.version = '1.2.3'
|
8
8
|
s.authors = ["Tute Costa"]
|
9
9
|
s.email = 'tutecosta@gmail.com'
|
10
10
|
s.add_dependency 'ambry', '~> 0.3.0'
|