Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

Merge branch 'main' into feat/improve-api

Kiran Kd14e5aee3e4a
diff --cc apps/web/lib/types.ts
index 68c40465de,83e94052fb..4f3df42afb
--- a/apps/web/lib/types.ts
+++ b/apps/web/lib/types.ts
@@@ -163,19 -173,3 +163,27 @@@ export interface SAMLProviderProps
token: string;
};
}
+
+export type NewLinkProps = z.infer<typeof createLinkBodySchema>;
+
- export const plans = ["free", "pro", "business", "enterprise"] as const;
++export const plans = [
++ "free",
++ "pro",
++ "business",
++ "business plus",
++ "business extra",
++ "business max",
++ "enterprise",
++] as const;
+
+export const roles = ["owner", "member"] as const;
+
+export const tagColors = [
+ "red",
+ "yellow",
+ "green",
+ "blue",
+ "purple",
+ "pink",
+ "brown",
+] as const;
diff --cc apps/web/ui/projects/upload-logo.tsx
index 3d74ed6db5,bdcabd1428..d0d355ac23
--- a/apps/web/ui/projects/upload-logo.tsx
+++ b/apps/web/ui/projects/upload-logo.tsx
@@@ -58,10 -58,12 +58,10 @@@ export default function UploadLogo()
mutate(`/api/projects/${slug}`),
]);
toast.success("Succesfully uploaded project logo!");
- return;
- } else if (res.status === 413) {
- toast.error("File size too big (max 2MB)");
+ } else {
- const errorMessage = await res.text();
- toast.error(errorMessage || "Something went wrong");
++ const { error } = await res.json();
++ toast.error(error.message);
}
- const { error } = await res.json();
- toast.error(error.message);
setUploading(false);
});
}}