Skip to content

Commit fbf6101

Browse files
authored
fix: don't mention Webpack in error messages when Vite is used (#12809)
1 parent d87e0f6 commit fbf6101

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

‎flow-plugins/flow-plugin-base/src/main/java/com/vaadin/flow/plugin/base/BuildFrontendUtil.java‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -423,9 +423,9 @@ private static void runFrontendBuildTool(PluginAdapterBase adapter,
423423
NODE_MODULES + executable);
424424
if (!buildExecutable.isFile()) {
425425
throw new IllegalStateException(String.format(
426-
"Unable to locate webpack executable by path '%s'. Double"
426+
"Unable to locate %s executable by path '%s'. Double"
427427
+ " check that the plugin is executed correctly",
428-
buildExecutable.getAbsolutePath()));
428+
toolName, buildExecutable.getAbsolutePath()));
429429
}
430430

431431
String nodePath;
@@ -461,7 +461,8 @@ private static void runFrontendBuildTool(PluginAdapterBase adapter,
461461
toolName, e.getResult().outputUTF8()), e);
462462
} catch (IOException | InterruptedException e) {
463463
throw new IllegalStateException(
464-
"Failed to run webpack due to an error", e);
464+
String.format("Failed to run %s due to an error", toolName),
465+
e);
465466
}
466467
}
467468

0 commit comments

Comments
 (0)