We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cd7f56b commit d86aef6Copy full SHA for d86aef6
app/controllers/application.rb
@@ -52,6 +52,12 @@ def current_user_cache_key
52
end
53
helper_method :current_user_cache_key
54
55
+ # Return a cache key for the current event.
56
+ def current_event_cache_key
57
+ return @event ? @event.id : -1
58
+ end
59
+ helper_method :current_event_cache_key
60
+
61
# Are we running in a development mode?
62
def development_mode?
63
return %w[development preview].include?(RAILS_ENV)
0 commit comments