Skip to content

Commit

Permalink
fix(done): Mark card as undone when updating card
Browse files Browse the repository at this point in the history
As stated in #534 (comment) updating the done property of a card via the REST API (without calling the /done and /undone endpoints explicitly) does only work "one way".

This commit allows setting null as new value thus allowing to mark cards as undone without an additional HTTP request but within a usual update request.

Refs: #534 #4137 c3b4ed6

Signed-off-by: Stefan Niedermann <[email protected]>

Signed-off-by: Niedermann IT-Dienstleistungen <[email protected]>
  • Loading branch information
stefan-niedermann authored Jan 18, 2024
1 parent 3fd1667 commit cf4d626
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/Service/CardService.php
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,8 @@ public function update($id, $title, $stackId, $type, $owner, $description = '',
}
if ($done !== null) {
$card->setDone($done->getValue());
} else {
$card->setDone(null);
}


Expand Down

0 comments on commit cf4d626

Please sign in to comment.