Topic: Accessing main app's CanCan rules from withing Rails 3.1 engine

I am trying to use a Forem gem which happens to utilise CanCan authorisation framework as well as my main application. Both the main application and Rails Engine have their own ability.rb files.

The problem happens in the layout, when I am trying to do some authorisation checks:

    <% if can? :update, User %>
        <%= link_to_current_user :content_method => :login %>.
    <% else %>

When I am utilising the layout file on the engine it consults it's own ability.rb file for authorisation. Naturally, there are no rules from my main application so authorisation fails when it should not. Is there any way for me to force it to go to the