Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Attempts to get the plugin to load on initialization

  • Loading branch information...
commit 1ab6ba45073b8399dfacb63a5507a73d49680d1f 1 parent 396b172
davidray authored
Showing with 21 additions and 18 deletions.
  1. +1 −18 lib/podcasts.rb
  2. +20 −0 lib/refinerycms-podcasts.rb
View
19 lib/podcasts.rb
@@ -1,18 +1 @@
-require 'refinery'
-
-module Refinery
- module Podcasts
- class Engine < Rails::Engine
- initializer "static assets" do |app|
- app.middleware.insert_after ::ActionDispatch::Static, ::ActionDispatch::Static, "#{root}/public"
- end
-
- config.after_initialize do
- Refinery::Plugin.register do |plugin|
- plugin.name = "podcasts"
- plugin.activity = {:class => Podcast}
- end
- end
- end
- end
-end
+require 'refinery'
View
20 lib/refinerycms-podcasts.rb
@@ -0,0 +1,20 @@
+require File.expand_path('../podcasts', __FILE__)
+
+module Refinery
+ module Podcasts
+ class Engine < Rails::Engine
+ initializer "static assets" do |app|
+ app.middleware.insert_after ::ActionDispatch::Static, ::ActionDispatch::Static, "#{root}/public"
+ end
+
+ config.after_initialize do
+ Refinery::Plugin.register do |plugin|
+ plugin.name = "podcasts"
+ plugin.directory = "podcasts"
+ plugin.menu_match = /(refinery|admin)\/podcast(s|_settings)$/
+ plugin.activity = {:class => Podcast}
+ end
+ end
+ end
+ end
+end
Please sign in to comment.
Something went wrong with that request. Please try again.