[ci] format
This commit is contained in:
parent
2c836b9d12
commit
be26e36e11
2 changed files with 4 additions and 2 deletions
|
@ -20,7 +20,10 @@ export const incompatPackageExp = new RegExp(`(${Object.keys(incompatiblePackage
|
||||||
* Useful for consistent reporting regardless of where the error surfaced from.
|
* Useful for consistent reporting regardless of where the error surfaced from.
|
||||||
*/
|
*/
|
||||||
export function collectErrorMetadata(e: any, rootFolder?: URL | undefined): ErrorWithMetadata {
|
export function collectErrorMetadata(e: any, rootFolder?: URL | undefined): ErrorWithMetadata {
|
||||||
const err = AggregateError.is(e) || Array.isArray((e as any).errors) ? (e.errors as SSRError[]) : [e as SSRError];
|
const err =
|
||||||
|
AggregateError.is(e) || Array.isArray((e as any).errors)
|
||||||
|
? (e.errors as SSRError[])
|
||||||
|
: [e as SSRError];
|
||||||
|
|
||||||
err.forEach((error) => {
|
err.forEach((error) => {
|
||||||
if (error.stack) {
|
if (error.stack) {
|
||||||
|
|
|
@ -26,5 +26,4 @@ describe('Astro.params in SSR', () => {
|
||||||
const $ = cheerio.load(html);
|
const $ = cheerio.load(html);
|
||||||
expect($('.category').text()).to.equal('food');
|
expect($('.category').text()).to.equal('food');
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue