Revert "fix(gitea-bot): add write:organization scope so bot can create repos"

This reverts commit 6f79a88abd.

Made-with: Cursor
This commit is contained in:
2026-04-21 11:12:20 -07:00
parent 6f79a88abd
commit 14835e2e0a
64 changed files with 1708 additions and 2068 deletions

View File

@@ -3,9 +3,7 @@
import { useEffect, useState } from "react";
import { useParams } from "next/navigation";
import { useSession } from "next-auth/react";
import { isClientDevProjectBypass } from "@/lib/dev-bypass";
import { Loader2 } from "lucide-react";
import { JM } from "@/components/project-creation/modal-theme";
import { FreshIdeaMain } from "@/components/project-main/FreshIdeaMain";
import { ChatImportMain } from "@/components/project-main/ChatImportMain";
import { CodeImportMain } from "@/components/project-main/CodeImportMain";
@@ -37,12 +35,10 @@ export default function ProjectOverviewPage() {
const [loading, setLoading] = useState(true);
useEffect(() => {
const bypass = isClientDevProjectBypass();
if (!bypass && authStatus !== "authenticated") {
if (authStatus !== "authenticated") {
if (authStatus === "unauthenticated") setLoading(false);
return;
}
if (!bypass && authStatus === "loading") return;
fetch(`/api/projects/${projectId}`)
.then(r => r.json())
.then(d => setProject(d.project))
@@ -52,23 +48,15 @@ export default function ProjectOverviewPage() {
if (loading) {
return (
<div style={{
display: "flex", alignItems: "center", justifyContent: "center",
height: "100%", fontFamily: JM.fontSans,
background: "linear-gradient(180deg, #FAFAFA 0%, #F5F3FF 100%)",
}}>
<Loader2 style={{ width: 24, height: 24, color: JM.indigo }} className="animate-spin" />
<div style={{ display: "flex", alignItems: "center", justifyContent: "center", height: "100%", fontFamily: "var(--font-inter), ui-sans-serif, sans-serif" }}>
<Loader2 style={{ width: 24, height: 24, color: "#a09a90" }} className="animate-spin" />
</div>
);
}
if (!project) {
return (
<div style={{
display: "flex", alignItems: "center", justifyContent: "center",
height: "100%", fontFamily: JM.fontSans, color: JM.muted, fontSize: 14,
background: "linear-gradient(180deg, #FAFAFA 0%, #F5F3FF 100%)",
}}>
<div style={{ display: "flex", alignItems: "center", justifyContent: "center", height: "100%", fontFamily: "var(--font-inter), ui-sans-serif, sans-serif", color: "#a09a90", fontSize: "0.88rem" }}>
Project not found.
</div>
);