Skip to content

Commit 2f53b14

Browse files
Need self. for module
1 parent e924fc4 commit 2f53b14

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/critical-path-css.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ module CriticalPathCss
44
CACHE_NAMESPACE = 'critical-path-css'
55
PENTHOUSE_PATH = "#{File.dirname(__FILE__)}/penthouse/penthouse.js"
66

7-
def generate_critical_css (main_css_path, base_url, routes)
7+
def self.generate (main_css_path, base_url, routes)
88
full_main_css_path = "#{Rails.root.to_s}/public#{main_css_path}"
99

1010
routes.each do |route|
@@ -13,7 +13,7 @@ def generate_critical_css (main_css_path, base_url, routes)
1313
end
1414
end
1515

16-
def fetch_critical_css (route)
16+
def self.fetch (route)
1717
Rails.cache.read(route, namespace: CACHE_NAMESPACE) || ''
1818
end
1919
end

0 commit comments

Comments
 (0)