tududi/frontend/components
Chris e8c7eed226
fix: prevent subtasks from disappearing when updating parent task (#984)
This commit addresses a critical bug where subtasks would disappear when
updating the parent task (e.g., assigning tags). The issue had multiple
potential causes:

1. Backend vulnerability: The updateSubtasks() function would delete all
   subtasks if an empty array was sent, treating it as "delete everything
   not in this list"

2. Frontend state management: After reloading a task, subtasks weren't
   being preserved if the backend response didn't include them

3. Unclear error messages: "Invalid parent task" errors didn't provide
   enough context for debugging

Changes:
- Added defensive logging in updateSubtasks() to warn when all subtasks
  are being deleted with an empty array
- Enhanced validateParentTaskAccess() error messages to provide detailed
  diagnostics (task not found vs. permission issues vs. wrong user)
- Updated handleTagsUpdate() in TaskDetails to explicitly preserve
  subtasks when reloading task after tag updates

This fix is defensive in nature and adds better observability for
diagnosing similar issues in the future.

Fixes issue reported by user where subtasks disappeared after assigning
tags to parent task, and "Invalid parent task" errors occurred when
trying to update the orphaned subtasks.
2026-04-01 17:37:20 +03:00
..
Admin Fix bug 578 (#648) 2025-12-04 14:00:51 +02:00
Area Set verification modal on escape (#470) (#473) 2025-11-03 16:27:13 +02:00
Backup Update translations 2025-12-10 11:43:15 +02:00
Calendar Fix profile settings mobile layout (#694) 2025-12-10 09:10:23 +02:00
Habits Fix bug 733 (#735) 2025-12-27 21:00:52 +02:00
Inbox Fix redirect after task deletion to return to originating view (#887) 2026-03-01 16:07:02 +02:00
Metrics Fix today race condition (#75) 2025-06-13 14:20:24 +03:00
Note Introduce focus mode in notes (#891) 2026-03-03 00:29:03 +02:00
Notifications Fix redirect after task deletion to return to originating view (#887) 2026-03-01 16:07:02 +02:00
Productivity Fix redirect after task deletion to return to originating view (#887) 2026-03-01 16:07:02 +02:00
Profile feat: Add MCP Integration with client-agnostic instructions (#953) 2026-03-20 16:55:49 +02:00
Project Fix project name overflow and add 6-word validation limit (#972) 2026-03-24 17:36:24 +02:00
Shared Fix missing spacing between lists and headings in markdown (#775) 2026-01-14 17:42:26 +02:00
Sidebar feat: Add MCP Integration with client-agnostic instructions (#953) 2026-03-20 16:55:49 +02:00
Tag Fix tag view showing completed projects when Open filter is active (#933) (#934) 2026-03-10 17:07:45 +02:00
Task fix: prevent subtasks from disappearing when updating parent task (#984) 2026-04-01 17:37:20 +03:00
UniversalSearch Fix redirect after task deletion to return to originating view (#887) 2026-03-01 16:07:02 +02:00
About.tsx Feat main content revamp (#584) 2025-11-20 09:15:55 +02:00
Areas.tsx Feat main content revamp (#584) 2025-11-20 09:15:55 +02:00
Calendar.tsx Fix redirect after task deletion to return to originating view (#887) 2026-03-01 16:07:02 +02:00
Login.tsx fix: use getAssetPath() for logo images in Navbar and Login (#946) 2026-03-18 15:26:25 +02:00
Navbar.tsx feat: Add MCP Integration with client-agnostic instructions (#953) 2026-03-20 16:55:49 +02:00
Notes.tsx Introduce focus mode in notes (#891) 2026-03-03 00:29:03 +02:00
Projects.tsx Fix projects order persist to localstorage (#868) 2026-02-27 00:35:44 +02:00
Register.tsx Refresh e2e tests (#606) 2025-11-29 21:25:42 +02:00
Sidebar.tsx feat: Add MCP Integration with client-agnostic instructions (#953) 2026-03-20 16:55:49 +02:00
Tags.tsx Feat improve task details (#585) 2025-11-21 18:43:10 +02:00
Tasks.tsx Fix sidebar toggle causing unnecessary task list reload (#888) (#937) 2026-03-10 18:37:07 +02:00
ViewDetail.tsx Fix bug 733 (#735) 2025-12-27 21:00:52 +02:00
Views.tsx Reorder elements (#687) 2025-12-09 10:51:51 +02:00