I figured it out. No need to roll back I think, although we need to take
a look at what the template installer does with your
application_controller.rb.
Jessie, can you tell me if you have a LOCAL
app/controllers/application_controller.rb, and if so, does it have a
line at the top that includes/requires/loads the BL distro
application_controller.rb ins ome way?
I had at the top of my _local_ application_controller.rb, this line:
eval
File.read('vendor/plugins/blacklight/app/controllers/application_controller.rb')
I have no idea where that came from, I guess some ancient way of doing
things, which doesn't make any sense. But it's that line that caused
the BL distro application_controller to be loaded twice, causing filters
to be applied twice.
So if you have that line in your application_controller.rb, remove it!
The current template installer instead puts this at the top of your
application_controller.rb:
require
'vendor/plugins/blacklight/app/controllers/application_controller.rb'
But guess what: That causes the problem too.
If you change that to require_dependency instead, it does NOT cause the
problem. However, in my case, simply _removing_ this logic altogether
works _fine_, Engines includes the base plugin application_controller.rb
all by itself, there is no need for ANY require/require_dependency line.
I think the template needs to be changed to _either_ use
"require_dependency" there instead of "require" OR simply remove this
step altogether. I would vote for removing it altogether, since as far
as I can tell it is entirely unneccesary.
Comments, Jessie or anyone else?
Jonathan