Files
wekan/server/models
Lauri Ojansivu c54e70f777 Time can be logged on imported cards whose spentTime was stored as null.
The board import stored spentTime: card.spentTime || null, and MongoDB and
FerretDB refuse the $inc that logs time on a null, so /cards/updateAsync
failed on every such card. The importers now store a Number. The Cards and
Boards before.update hooks turn an $inc of a stored non-number into the $set
of the sum (models/lib/spentTime.js) - not an update pipeline, which FerretDB
v1, Minimongo and allow/deny refuse. The startup step spenttime-null-repair
resets the stored nulls to 0. Checked against FerretDB: the bare $inc and the
pipeline are both refused there, the hook's $set and the repair step work.

Thanks to Raymond-Voogt and xet7 !

Fixes #6940.
2026-11-23 21:45:05 +02:00
..
2026-06-06 02:53:58 +03:00