File tree Expand file tree Collapse file tree 3 files changed +7
-7
lines changed
lib/action_controller/caching Expand file tree Collapse file tree 3 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ authentication and other restrictions on whether someone is allowed
29
29
to execute such action.
30
30
31
31
class ListsController < ApplicationController
32
- before_filter :authenticate, except: :public
32
+ before_action :authenticate, except: :public
33
33
34
34
caches_page :public
35
35
caches_action :index, :show
@@ -72,7 +72,7 @@ interval (in seconds) to schedule expiration of the cached item.
72
72
The following example depicts some of the points made above:
73
73
74
74
class ListsController < ApplicationController
75
- before_filter :authenticate, except: :public
75
+ before_action :authenticate, except: :public
76
76
77
77
caches_page :public
78
78
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ module Caching
10
10
# to execute such action.
11
11
#
12
12
# class ListsController < ApplicationController
13
- # before_filter :authenticate, except: :public
13
+ # before_action :authenticate, except: :public
14
14
#
15
15
# caches_page :public
16
16
# caches_action :index, :show
@@ -66,7 +66,7 @@ module Caching
66
66
#
67
67
#
68
68
# class ListsController < ApplicationController
69
- # before_filter :authenticate, except: :public
69
+ # before_action :authenticate, except: :public
70
70
#
71
71
# caches_page :public
72
72
#
@@ -113,7 +113,7 @@ def caches_action(*actions)
113
113
filter_options = options . extract! ( :if , :unless ) . merge ( only : actions )
114
114
cache_options = options . extract! ( :layout , :cache_path ) . merge ( store_options : options )
115
115
116
- around_filter ActionCacheFilter . new ( cache_options ) , filter_options
116
+ around_action ActionCacheFilter . new ( cache_options ) , filter_options
117
117
end
118
118
end
119
119
Original file line number Diff line number Diff line change @@ -25,9 +25,9 @@ class ActionCachingTestController < CachingController
25
25
end
26
26
27
27
# Eliminate uninitialized ivar warning
28
- before_filter { @title = nil }
28
+ before_action { @title = nil }
29
29
30
- before_filter only : :with_symbol_format do
30
+ before_action only : :with_symbol_format do
31
31
request . params [ :format ] = :json
32
32
end
33
33
You can’t perform that action at this time.
0 commit comments