Updating a card on an incoming federated board without `done` returns 500
Maintainers usually reply within 1 day
@AlirezaAghaee1996 is already working on this.
Since Nov 28, 2026.
- #8823 by @AlirezaAghaee1996 — open
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 78/100
Research direction
The crash is in ExternalBoardService::updateCardOnRemote() in lib/Service/ExternalBoardService.php, where $done is dereferenced at about line 175 without a null check. Read that method and the parameters it forwards to DeckFederationProxy::put(), then add unit tests for calls without done, with a value, and with an explicit null. Done means an update without done is forwarded to the owner with no done key and returns 200 instead of 500.
Written by the indexing model from the issue text.
Description
Describe the bug
ExternalBoardService::updateCardOnRemote() calls $done->getValue(), but $done is null when the request has no done key:
https://github.com/nextcloud/deck/blob/bf65da22e13a366c70c72391beaee00ed2152810/lib/Service/ExternalBoardService.php#L175
Updating a card on an incoming federated board through the API then fails before anything is sent to the owner.
To Reproduce
- Share a board from instance B with a user on instance A.
- As that user on instance A, call
PUT /ocs/v2.php/apps/deck/api/v1.0/cards/{cardId}withid,boardId(the local board id),stackId,title,type,order,description,duedateanddeletedAt, but withoutdone. - Response 500. Log:
Call to a member function getValue() on null in …/lib/Service/ExternalBoardService.php line 175.
Expected behavior
The update is forwarded to the owner.
Suggested fix
Only forward done when the client sent it, so the owner handles the request the same way as a local update with the same parameters:
$params = [
// … all current keys except 'done' …
];
if ($done !== null) {
$params['done'] = $done->getValue();
}
Unit tests can call updateCardOnRemote() without done, with a value and with an explicit null, and check the parameters passed to DeckFederationProxy::put(). I tested this change with unit tests and on the two instances below: the update now returns 200 and arrives at the owner.
Server details
Two instances, both Docker, MariaDB 11.8 / MySQL, PHP 8.5.13:
- Instance A: Nextcloud 35.0.3, Deck 1.19.2
- Instance B: Nextcloud 34.0.6, Deck 1.18.7
The code paths are unchanged on main (bf65da22e).
This report was drafted with AI assistance (Claude Code) and reproduced on the two instances above.
- Dominant language
- JavaScript
- Stars
- 1.4k
- Forks
- 380
- Avg merge
- 1d 17h
- Merged PRs (30d)
- 72
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from nextcloud/deck
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
2 small URL BugsOpen1. to develop bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
nextcloud/deck#8834 · 1 comment ·
Maintainers usually reply within 1 day
-
Updating a card without `done` clears its done statePossibly taken @whoalin1 claimed this 5 days ago. Open0. Needs triage bug
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Deck treats unset files_sharing server-to-server keys as disabledPossibly taken @whoalin1 claimed this 5 days ago. Open0. Needs triage bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
vecture-be/belgium-data-desk#181 ·
Maintainers usually reply within 1 day
-
enhancement frontend reconciliation UX
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
humlab-sead/sead_shape_shifter#882 ·
Maintainers usually reply within 1 day
-
good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
erkamyaman/rust-anything#1381 ·
Maintainers usually reply within 1 day
-
a11y accessibility area: i18n area: pages area: sites bug i18n priority: P2 seo tech: javascript tests
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
flisk-sh/chat#833 · 1 comment ·
Maintainers usually reply within 1 day