Skip to content

Commit 2f59cd0

Browse files
fix: improve JetBrains error message to mention Toolbox requirement (#18294)
Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com> Co-authored-by: kylecarbs <7122116+kylecarbs@users.noreply.github.com>
1 parent 98a9aa1 commit 2f59cd0

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

site/src/modules/apps/useAppLink.ts

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,19 @@ export const useAppLink = (
5050
// an error message will be displayed.
5151
const openAppExternallyFailedTimeout = 500;
5252
const openAppExternallyFailed = setTimeout(() => {
53-
displayError(`${label} must be installed first.`);
53+
// Check if this is a JetBrains IDE app
54+
const isJetBrainsApp =
55+
app.url &&
56+
(app.url.startsWith("jetbrains-gateway:") ||
57+
app.url.startsWith("jetbrains:"));
58+
59+
if (isJetBrainsApp) {
60+
displayError(
61+
`To use ${label}, you need to have JetBrains Toolbox installed.`,
62+
);
63+
} else {
64+
displayError(`${label} must be installed first.`);
65+
}
5466
}, openAppExternallyFailedTimeout);
5567
window.addEventListener("blur", () => {
5668
clearTimeout(openAppExternallyFailed);

0 commit comments

Comments
 (0)