diff --git a/ManagerService/Controllers/MigrationController.cs b/ManagerService/Controllers/MigrationController.cs index d3607ef..6ee5af1 100644 --- a/ManagerService/Controllers/MigrationController.cs +++ b/ManagerService/Controllers/MigrationController.cs @@ -306,7 +306,11 @@ namespace ManagerService.Controllers Email = old.Email, Password = old.Password, FirstName = old.FirstName, - LastName = old.LastName, + // Mongo n'impose rien sur le nom, Postgres le veut NOT NULL : + // `test@email.be` a LastName null et faisait échouer tout le + // lot au SaveChanges. Le dry run ne peut pas voir ce défaut — + // il n'écrit rien, donc aucune contrainte n'est évaluée. + LastName = old.LastName ?? string.Empty, Token = old.Token, DateCreation = old.DateCreation, InstanceId = old.InstanceId,