@@ -6,6 +6,12 @@ class ApplicationController < ActionController::Base |
||
| 6 | 6 |
|
| 7 | 7 |
helper :all |
| 8 | 8 |
|
| 9 |
+ def redirect_back(fallback_path, *args) |
|
| 10 |
+ redirect_to :back, *args |
|
| 11 |
+ rescue ActionController::RedirectBackError |
|
| 12 |
+ redirect_to fallback_path, *args |
|
| 13 |
+ end |
|
| 14 |
+ |
|
| 9 | 15 |
protected |
| 10 | 16 |
|
| 11 | 17 |
def configure_permitted_parameters |