[PR #2446] [MERGED] fix: check child project's own IsArchived flag in CheckIsArchived #8274

Closed
opened 2026-04-20 18:07:35 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/go-vikunja/vikunja/pull/2446
Author: @tink-bot
Created: 3/23/2026
Status: Merged
Merged: 3/23/2026
Merged by: @kolaente

Base: mainHead: fix/check-is-archived-child-project


📝 Commits (2)

  • 83840df fix: check child project's own IsArchived flag in CheckIsArchived
  • c797fc3 fix: update ParadeDB search test count for new fixture

📊 Changes

4 files changed (+74 additions, -10 deletions)

View changed files

📝 pkg/db/fixtures/projects.yml (+13 -0)
📝 pkg/models/project.go (+11 -6)
📝 pkg/models/project_test.go (+49 -3)
📝 pkg/webtests/project_test.go (+1 -1)

📄 Description

CheckIsArchived() skipped checking a child project's own IsArchived flag when ParentProjectID > 0, immediately recursing to only check the parent. This allowed all write operations (task creation, updates, deletions, label/assignee/comment operations) on individually archived child projects whose parent was not archived.

Additionally fixes variable shadowing that prevented multi-level parent checking and ensures new projects (ID=0) still validate their parent's archived state.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/go-vikunja/vikunja/pull/2446 **Author:** [@tink-bot](https://github.com/tink-bot) **Created:** 3/23/2026 **Status:** ✅ Merged **Merged:** 3/23/2026 **Merged by:** [@kolaente](https://github.com/kolaente) **Base:** `main` ← **Head:** `fix/check-is-archived-child-project` --- ### 📝 Commits (2) - [`83840df`](https://github.com/go-vikunja/vikunja/commit/83840df422ce6c5c3852c47c8c7d97cee6b51204) fix: check child project's own IsArchived flag in CheckIsArchived - [`c797fc3`](https://github.com/go-vikunja/vikunja/commit/c797fc32662f042141506a2888c26c16d0609798) fix: update ParadeDB search test count for new fixture ### 📊 Changes **4 files changed** (+74 additions, -10 deletions) <details> <summary>View changed files</summary> 📝 `pkg/db/fixtures/projects.yml` (+13 -0) 📝 `pkg/models/project.go` (+11 -6) 📝 `pkg/models/project_test.go` (+49 -3) 📝 `pkg/webtests/project_test.go` (+1 -1) </details> ### 📄 Description `CheckIsArchived()` skipped checking a child project's own `IsArchived` flag when `ParentProjectID > 0`, immediately recursing to only check the parent. This allowed all write operations (task creation, updates, deletions, label/assignee/comment operations) on individually archived child projects whose parent was not archived. Additionally fixes variable shadowing that prevented multi-level parent checking and ensures new projects (ID=0) still validate their parent's archived state. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-20 18:07:35 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vikunja#8274