File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
app/services/forest_liana Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ def set_has_many_relationships
5353 end
5454
5555 def has_strong_parameter
56- Rails ::VERSION ::MAJOR > 5 || @resource . instance_method ( :update_attributes ! ) . arity == 1
56+ Rails ::VERSION ::MAJOR > 5 || @resource . instance_method ( :update ! ) . arity == 1
5757 end
5858 end
5959end
Original file line number Diff line number Diff line change @@ -14,9 +14,9 @@ def perform
1414 @record = @resource . find ( @params [ :id ] )
1515
1616 if has_strong_parameter
17- @record . update_attributes ( resource_params )
17+ @record . update ( resource_params )
1818 else
19- @record . update_attributes ( resource_params , without_protection : true )
19+ @record . update ( resource_params , without_protection : true )
2020 end
2121 rescue ActiveRecord ::StatementInvalid => exception
2222 # NOTICE: SQL request cannot be executed properly
@@ -33,7 +33,7 @@ def resource_params
3333 end
3434
3535 def has_strong_parameter
36- Rails ::VERSION ::MAJOR > 5 || @resource . instance_method ( :update_attributes ! ) . arity == 1
36+ Rails ::VERSION ::MAJOR > 5 || @resource . instance_method ( :update ! ) . arity == 1
3737 end
3838 end
3939end
You can’t perform that action at this time.
0 commit comments