0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2024-12-30 22:03:56 -05:00

Give proper error when seed missing default export (#10635)

This commit is contained in:
Matthew Phillips 2024-04-01 14:18:46 -04:00 committed by GitHub
parent ca29764912
commit 17badaf55c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 6 additions and 1 deletions

View file

@ -0,0 +1,5 @@
---
"@astrojs/db": patch
---
Give proper error when seed missing default export

View file

@ -58,7 +58,7 @@ export async function cmd({
const mod = await importBundledFile({ code, root: astroConfig.root });
if (typeof mod.default !== 'function') {
console.error(EXEC_DEFAULT_EXPORT_ERROR);
console.error(EXEC_DEFAULT_EXPORT_ERROR(filePath));
process.exit(1);
}
try {