lib/octopress-ink/assets/layout.rb in octopress-ink-1.0.0.alpha.24 vs lib/octopress-ink/assets/layout.rb in octopress-ink-1.0.0.alpha.25
- old
+ new
@@ -1,20 +1,20 @@
module Octopress
module Assets
class Layout < Asset
- def register(site)
+ def register
name = "#{@plugin.namespace}:#{@file}"
name = name.split(".")[0..-2].join(".")
- file = user_path(site)
- dir = user_dir(site)
+ file = user_path
+ dir = user_dir
if !exists?(file)
file = plugin_path
dir = plugin_dir
end
- site.layouts[name] = Jekyll::Layout.new(site, dir, @file)
+ Plugins.site.layouts[name] = Jekyll::Layout.new(Plugins.site, dir, @file)
end
end
end
end