-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix delete confirmation with new Rails syntax #1326
Conversation
…confirmation to "Are you sure" translation
0ab219c
to
5477495
Compare
|
||
link_to(t(:delete) + "!", | ||
options[:url] || url_for(record), | ||
method: :delete, | ||
remote: true, | ||
confirm: confirm) | ||
data: { confirm: confirm}) |
Check notice
Code scanning / Rubocop
Prefer Ruby 1.9 hash syntax { a: 1, b: 2 } over 1.8 syntax { :a => 1, :b => 2 }. Note
|
||
link_to(t(:delete) + "!", | ||
options[:url] || url_for(record), | ||
method: :delete, | ||
remote: true, | ||
confirm: confirm) | ||
data: { confirm: confirm}) |
Check notice
Code scanning / Rubocop
Use spaces inside hash literal braces - or don't. Note
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you! Yes this restores the functionality to ask for confirmation before completing a destructive action. Code is now compatible with latest rails release.
Fixed Delete confirmation with new Rails syntax
Changed default delete confirmation action from NIL to "Are you sure" translation