app controller: clean up helpers.
* Move `show_moderation_notice?` out. * Don't need to declare `helper :pagination` manually.
This commit is contained in:
@@ -217,6 +217,10 @@ module ApplicationHelper
|
||||
end
|
||||
end
|
||||
|
||||
def show_moderation_notice?
|
||||
CurrentUser.can_approve_posts? && (cookies[:moderated].blank? || Time.at(cookies[:moderated].to_i) < 20.hours.ago)
|
||||
end
|
||||
|
||||
protected
|
||||
def nav_link_match(controller, url)
|
||||
url =~ case controller
|
||||
|
||||
Reference in New Issue
Block a user