Skip to content

Conversation

@github-actions
Copy link
Contributor

@github-actions github-actions bot commented Dec 8, 2025

This is an automated pull request to release the candidate branch into production, which will trigger a deployment.
It was created by the [Production PR] action.

* feat(organization): add transfer ownership functionality and do visible the section del organization only for owner

* feat(organization): implement transfer ownership endpoint and update related schemas

* fix(organization): throw BadRequestException for missing user ID in transfer ownership

---------

Co-authored-by: Tofik Hasanov <annexcies@gmail.com>
@vercel
Copy link

vercel bot commented Dec 8, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
app (staging) Ready Ready Preview Comment Dec 8, 2025 7:45pm
1 Skipped Deployment
Project Deployment Preview Comments Updated (UTC)
portal (staging) Skipped Skipped Dec 8, 2025 7:45pm

@cursor
Copy link

cursor bot commented Dec 8, 2025

PR Summary

Adds organization ownership transfer (backend + UI) and updates auditor job to use Groq model and Firecrawl v2, with OpenAPI docs updated.

  • Organization (Backend):
    • New endpoint: POST /v1/organization/transfer-ownership with DTOs, request body schema, and responses; validates current owner and updates roles transactionally (owner → current user loses owner, becomes admin; new member gains owner).
    • Controller/Service: Implements transferOwnership with auth checks and detailed logging.
    • Docs: Swagger/OpenAPI bodies, operations, and responses added.
  • Organization (Frontend):
    • Settings Page (apps/app/src/app/(app)/[orgId]/settings/page.tsx): loads orgId, fetches ownership context, renders TransferOwnership and gates DeleteOrganization by isOwner.
    • New UI: components/forms/organization/transfer-ownership.tsx to select member and confirm transfer; uses /v1/organization/transfer-ownership.
    • Delete Organization: component now hidden unless isOwner.
  • Jobs:
    • Auditor task: switch model to groq('openai/gpt-oss-120b'); migrate Firecrawl API from v1 to v2 with polling, enhanced logging, and structured data handling.
  • Docs:
    • OpenAPI: adds paths./v1/organization/transfer-ownership.

Written by Cursor Bugbot for commit d50d0d3. This will update automatically on new commits. Configure here.

@graphite-app graphite-app bot requested a review from Marfuen December 8, 2025 19:15
@CLAassistant
Copy link

CLAassistant commented Dec 8, 2025

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ Marfuen
❌ github-actions[bot]
You have signed the CLA already but the status is still pending? Let us recheck it.

@graphite-app
Copy link

graphite-app bot commented Dec 8, 2025

Graphite Automations

"Auto-assign PRs to Author" took an action on this PR • (12/08/25)

1 reviewer was added to this PR based on Mariano Fuentes's automation.

params: Promise<{ orgId: string }>;
}) {
const { orgId } = await params;
console.log('[OrganizationSettings Debug] orgId:', orgId);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Debug console.log statement left in production code

A debug console.log('[OrganizationSettings Debug] orgId:', orgId) statement was left in the production code. This appears to be debugging output that was accidentally committed and will log organization IDs to the server console on every settings page load.

Fix in Cursor Fix in Web

// Get current user's member record
const currentUserMember = await db.member.findFirst({
where: { organizationId, userId: currentUserId },
});
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Deactivated owner can still transfer ownership

The query for currentUserMember does not filter by deactivated: false, but the newOwnerMember query does. This inconsistency could allow a deactivated member who still has the owner role to transfer ownership, even though they are supposed to be inactive. Adding deactivated: false to the currentUserMember query would make the checks consistent.

Fix in Cursor Fix in Web

@vercel vercel bot temporarily deployed to staging – portal December 8, 2025 19:42 Inactive
@Marfuen Marfuen merged commit 98907bd into release Dec 8, 2025
9 of 11 checks passed
@claudfuen
Copy link
Contributor

🎉 This PR is included in version 1.70.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants