From 3238300f93969d35a01f012b1bba69d96600e92f Mon Sep 17 00:00:00 2001 From: Yuji Yaginuma Date: Tue, 17 Dec 2024 11:13:35 +0900 Subject: [PATCH] Fix an example for resetting the state every request `before_filter` was removed by Rails v5.1.0. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index c065744..148b671 100644 --- a/README.md +++ b/README.md @@ -562,7 +562,7 @@ Call `Model.reload(true)` to force reload the data from disk. In Rails, you can use this snippet. Please just note it resets the state every request, which may not always be desired. ```ruby -before_filter do +before_action do [Model1, Model2, Model3].each { |m| m.reload(true) } end ```