haml-edge 2.3.72 → 2.3.73
Sign up to get free protection for your applications and to get access to all the features.
- data/EDGE_GEM_VERSION +1 -1
- data/VERSION +1 -1
- data/lib/haml/util.rb +2 -2
- data/lib/sass/plugin/rails.rb +17 -9
- metadata +1 -1
data/EDGE_GEM_VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.3.
|
1
|
+
2.3.73
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.3.
|
1
|
+
2.3.73
|
data/lib/haml/util.rb
CHANGED
@@ -141,8 +141,8 @@ module Haml
|
|
141
141
|
#
|
142
142
|
# @return [String, nil]
|
143
143
|
def rails_root
|
144
|
-
return Rails.root if defined?(Rails.root)
|
145
|
-
return RAILS_ROOT if defined?(RAILS_ROOT)
|
144
|
+
return Rails.root.to_s if defined?(Rails.root)
|
145
|
+
return RAILS_ROOT.to_s if defined?(RAILS_ROOT)
|
146
146
|
return nil
|
147
147
|
end
|
148
148
|
|
data/lib/sass/plugin/rails.rb
CHANGED
@@ -7,16 +7,24 @@ unless defined?(Sass::RAILS_LOADED)
|
|
7
7
|
:always_check => RAILS_ENV != "production",
|
8
8
|
:full_exception => RAILS_ENV != "production")
|
9
9
|
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
Sass::Plugin.update_stylesheets
|
17
|
-
end
|
10
|
+
check = lambda do
|
11
|
+
if !Sass::Plugin.checked_for_updates ||
|
12
|
+
Sass::Plugin.options[:always_update] || Sass::Plugin.options[:always_check]
|
13
|
+
Sass::Plugin.update_stylesheets
|
14
|
+
end
|
15
|
+
end
|
18
16
|
|
19
|
-
|
17
|
+
if defined?(ActionDispatch::Callbacks.to_prepare)
|
18
|
+
# Rails >= 3.0.0
|
19
|
+
ActionDispatch::Callbacks.to_prepare(&check)
|
20
|
+
else
|
21
|
+
module ActionController
|
22
|
+
class Base
|
23
|
+
alias_method :sass_old_process, :process
|
24
|
+
def process(*args)
|
25
|
+
check.call
|
26
|
+
sass_old_process(*args)
|
27
|
+
end
|
20
28
|
end
|
21
29
|
end
|
22
30
|
end
|