Don’t use unless
This commit is contained in:
parent
8c73851cec
commit
7c34807f46
90 changed files with 164 additions and 157 deletions
|
@ -2,7 +2,7 @@ class LinkTypePieceJointeToFormulaire < ActiveRecord::Migration
|
|||
# def up
|
||||
# TypePieceJointe.find_each do |type_piece_jointe|
|
||||
# forms = Formulaire.find_by_demarche_id(type_piece_jointe.CERFA)
|
||||
# type_piece_jointe.update_attributes(formulaire_id: forms.id) unless forms.nil?
|
||||
# type_piece_jointe.update_attributes(formulaire_id: forms.id) if forms.present?
|
||||
# end
|
||||
# end
|
||||
end
|
||||
|
|
|
@ -24,7 +24,7 @@ class CreateFranceConnectInformation < ActiveRecord::Migration
|
|||
birthdate: user.birthdate,
|
||||
birthplace: user.birthplace,
|
||||
france_connect_particulier_id: user.france_connect_particulier_id,
|
||||
user_id: user.id}) unless user.france_connect_particulier_id.nil?
|
||||
user_id: user.id}) if user.france_connect_particulier_id.present?
|
||||
end
|
||||
|
||||
remove_column :users, :gender
|
||||
|
|
|
@ -33,7 +33,7 @@ class BuildDefaultPrefListDossierProcedure < ActiveRecord::Migration
|
|||
base_object = gestionnaire.preference_list_dossiers.where(procedure: nil).size
|
||||
created_object = gestionnaire.preference_list_dossiers.where(procedure: procedure).size
|
||||
|
||||
raise "ERROR nb object (#{base_object} != #{created_object})" unless created_object == base_object
|
||||
raise "ERROR nb object (#{base_object} != #{created_object})" if created_object != base_object
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue