You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Rails, flash.now should never end up with redirect_to, and flash (without .now) should normally not end up at "render". However, it's not that hard to make that mistake, especially after making other changes. I think it'd be useful for rails_best_practices to detect that case.
E.g., detect misuses like this:
flash.now[:danger]=t('admin_only')redirect_to'/'
The text was updated successfully, but these errors were encountered:
Here's an enhancement idea.
In Rails, flash.now should never end up with redirect_to, and flash (without .now) should normally not end up at "render". However, it's not that hard to make that mistake, especially after making other changes. I think it'd be useful for rails_best_practices to detect that case.
E.g., detect misuses like this:
The text was updated successfully, but these errors were encountered: