Next.js website for Rocky Mountain Vending company featuring: - Product catalog with Stripe integration - Service areas and parts pages - Admin dashboard with Clerk authentication - SEO optimized pages with JSON-LD structured data Co-authored-by: Cursor <cursoragent@cursor.com>
9 lines
307 B
Text
9 lines
307 B
Text
export const asSdkError = (error) => {
|
|
if (error instanceof Error)
|
|
return error;
|
|
if (error instanceof Object)
|
|
return Object.assign(new Error(), error);
|
|
if (typeof error === "string")
|
|
return new Error(error);
|
|
return new Error(`AWS SDK error wrapper for ${error}`);
|
|
};
|