Commit 5dd85ce3 authored by Nicolas Frandeboeuf's avatar Nicolas Frandeboeuf Committed by Nicolas Frandeboeuf

Fix m6 migration (operationTypeID not deleted)

parent c9da4fed
......@@ -242,14 +242,16 @@ let migrations = [
}
for (let operation of operations) {
let type;
if (operation.operationTypeID && typeMap.has(operation.operationTypeID)) {
operation.type = typeMap.get(operation.operationTypeID);
type = typeMap.get(operation.operationTypeID);
} else {
operation.type = UNKNOWN_OPERATION_TYPE;
type = UNKNOWN_OPERATION_TYPE;
}
delete operation.operationTypeID;
let update = { type: operation.type };
await Transactions.update(userId, operation.id, update);
await Transactions.update(userId, operation.id, {
type,
operationTypeID: null
});
}
// Delete operation types
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment