[autofix.ci] apply automated fixes

This commit is contained in:
autofix-ci[bot]
2025-09-27 08:20:36 +00:00
committed by GitHub
parent 6fa8f63277
commit b725861b55
2 changed files with 25 additions and 11 deletions

View File

@@ -7,7 +7,14 @@ import {
import { cn } from "@/lib/utils";
interface Props {
status: "running" | "error" | "done" | "idle" | "cancelled" | undefined | null;
status:
| "running"
| "error"
| "done"
| "idle"
| "cancelled"
| undefined
| null;
className?: string;
}
@@ -36,7 +43,10 @@ export const StatusTooltip = ({ status, className }: Props) => {
)}
{status === "cancelled" && (
<div
className={cn("size-3.5 rounded-full bg-muted-foreground", className)}
className={cn(
"size-3.5 rounded-full bg-muted-foreground",
className,
)}
/>
)}
{status === "running" && (

View File

@@ -3,15 +3,19 @@ import { eq } from "drizzle-orm";
import { db } from "../../db/index";
export const initCancelDeployments = async () => {
try {
console.log("Setting up cancel deployments....");
try {
console.log("Setting up cancel deployments....");
const result = await db.update(deployments).set({
status: "cancelled",
}).where(eq(deployments.status, "running")).returning();
const result = await db
.update(deployments)
.set({
status: "cancelled",
})
.where(eq(deployments.status, "running"))
.returning();
console.log(`Cancelled ${result.length} deployments`);
} catch (error) {
console.error(error);
}
console.log(`Cancelled ${result.length} deployments`);
} catch (error) {
console.error(error);
}
};