Skip to content

Commit 62faedc

Browse files
committed
fix: ensure forms test is actually testing!
1 parent a964c7a commit 62faedc

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/build/verification.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -96,12 +96,12 @@ export async function verifyNetlifyFormsWorkaround(ctx: PluginContext) {
9696
const srcDir = ctx.resolveFromSiteDir('public')
9797
const paths = await glob(join(srcDir, '**/*.html'))
9898
try {
99-
const hasWorkaround = await paths.some(async (path): Promise<boolean> => {
99+
for (const path of paths) {
100100
const html = await readFile(path, 'utf-8')
101-
return formDetectionRegex.test(html)
102-
})
103-
if (hasWorkaround) {
104-
verifications.add('netlifyFormsWorkaround')
101+
if (formDetectionRegex.test(html)) {
102+
verifications.add('netlifyFormsWorkaround')
103+
return
104+
}
105105
}
106106
} catch (error) {
107107
ctx.failBuild('Failed verifying public files', error)

0 commit comments

Comments
 (0)