simplify a bit more

This commit is contained in:
simon lehericey 2022-04-30 15:57:34 +02:00
parent 35ae011b59
commit 1ef8d99e6e

View file

@ -48,10 +48,8 @@ class ProcedureRevision < ApplicationRecord
.tap do |types_de_champ|
params[:order_place] = types_de_champ.present? ? types_de_champ.last.order_place + 1 : 0
end.create(params).migrate_parent!
elsif params[:private]
types_de_champ_private.create(params)
else
types_de_champ_public.create(params)
types_de_champ.create(params)
end
end