Skip to content

fix: reset sponsor page on new customized page#942

Open
tomrndom wants to merge 1 commit into
masterfrom
fix/sponsor-new-customized-page
Open

fix: reset sponsor page on new customized page#942
tomrndom wants to merge 1 commit into
masterfrom
fix/sponsor-new-customized-page

Conversation

@tomrndom
Copy link
Copy Markdown

@tomrndom tomrndom commented May 15, 2026

ref: https://app.clickup.com/t/86b9yh4rv

Signed-off-by: Tomás Castillo tcastilloboireau@gmail.com

Summary by CodeRabbit

  • Bug Fixes
    • Fixed an issue where adding a new sponsor page could retain state from the previous page, ensuring a clean slate when creating new pages.

Review Change Stack

Signed-off-by: Tomás Castillo <tcastilloboireau@gmail.com>
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 15, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 6667d73f-cb85-4eb9-ad27-1d98b5cc773d

📥 Commits

Reviewing files that changed from the base of the PR and between 45ffe84 and c72c4df.

📒 Files selected for processing (1)
  • src/pages/sponsors/sponsor-page/tabs/sponsor-pages-tab/index.js

📝 Walkthrough

Walkthrough

The PR adds a single state-clearing call to the sponsor page add flow. handleAddPage now invokes resetSponsorPage() before opening the customized page popup, ensuring previous sponsor page data does not persist when initiating a new page creation.

Changes

Sponsor page add flow

Layer / File(s) Summary
Reset state before new page popup
src/pages/sponsors/sponsor-page/tabs/sponsor-pages-tab/index.js
handleAddPage calls resetSponsorPage() before opening the new custom page popup, clearing any residual sponsor page state from prior operations.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Possibly related PRs

  • fntechgit/summit-admin#805: Introduced resetSponsorPage() for the custom sponsor page add/edit flow, which this PR now applies at the entry point of the add page action.

Suggested reviewers

  • smarcet

Poem

🐰 A single reset clears the way,
Before a new page starts its day,
Fresh state, fresh start, no ghosts remain—
A tiny fix, but oh so sane!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title directly and accurately describes the main change: resetting sponsor page state when creating a new customized page.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/sponsor-new-customized-page

Comment @coderabbitai help to get the list of available commands and usage tips.

@tomrndom tomrndom requested a review from smarcet May 15, 2026 16:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant