Skip to content

Commit

Permalink
Prefer local_prefixes over the private _prefixes method
Browse files Browse the repository at this point in the history
  • Loading branch information
jcoyne committed Nov 15, 2016
1 parent 8988914 commit 19bd581
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
Expand Up @@ -48,7 +48,8 @@ def add_breadcrumb_for_controller
end

def _prefixes
# This allows us to use the templates in curation_concerns/base
# This allows us to use the templates in curation_concerns/base, while prefering
# our local paths. Thus we are unable to just override `self.local_prefixes`
@_prefixes ||= super + ['curation_concerns/base']
end

Expand Down
10 changes: 5 additions & 5 deletions app/controllers/concerns/sufia/file_sets_controller_behavior.rb
Expand Up @@ -44,12 +44,12 @@ def add_breadcrumb_for_action
end
end

protected
# This allows us to use the templates in curation_concerns/file_sets
def self.local_prefixes
['curation_concerns/file_sets']
end

def _prefixes
# This allows us to use the templates in curation_concerns/file_sets
@_prefixes ||= ['curation_concerns/file_sets'] + super
end
protected

def initialize_edit_form
@version_list = version_list
Expand Down

0 comments on commit 19bd581

Please sign in to comment.