diff options
-rw-r--r-- | lib/refinerycms-blog.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/refinerycms-blog.rb b/lib/refinerycms-blog.rb index 407b840..752cba3 100644 --- a/lib/refinerycms-blog.rb +++ b/lib/refinerycms-blog.rb @@ -6,6 +6,10 @@ module Refinery autoload :Tab, File.expand_path("../refinery/blog/tabs", __FILE__) class << self + attr_accessor :root + def root + @root ||= Pathname.new(File.expand_path('../../', __FILE__)) + end def version ::Refinery::Blog::Version.to_s end @@ -22,6 +26,7 @@ module Refinery config.after_initialize do Refinery::Plugin.register do |plugin| + plugin.pathname = root plugin.name = "refinerycms_blog" plugin.url = {:controller => '/admin/blog/posts', :action => 'index'} plugin.menu_match = /^\/?(admin|refinery)\/blog\/?(posts|comments|categories)?/ |