aboutsummaryrefslogtreecommitdiffstats
path: root/packages/meshbay-hub/src/meshbay_hub/static/files-app.js
diff options
context:
space:
mode:
Diffstat (limited to 'packages/meshbay-hub/src/meshbay_hub/static/files-app.js')
-rw-r--r--packages/meshbay-hub/src/meshbay_hub/static/files-app.js11
1 files changed, 8 insertions, 3 deletions
diff --git a/packages/meshbay-hub/src/meshbay_hub/static/files-app.js b/packages/meshbay-hub/src/meshbay_hub/static/files-app.js
index 75005e2..3d51e67 100644
--- a/packages/meshbay-hub/src/meshbay_hub/static/files-app.js
+++ b/packages/meshbay-hub/src/meshbay_hub/static/files-app.js
@@ -44,9 +44,14 @@ function FilesPanel({
const downloadFile = useCallback(async (entry) => {
let transport, gek;
if (getTransport) {
- const conn = await getTransport(entry);
- transport = conn.transport;
- gek = conn.gek;
+ try {
+ const conn = await getTransport(entry);
+ transport = conn.transport;
+ gek = conn.gek;
+ } catch {
+ setError(t('search.unreachable', { n: 1 }));
+ return;
+ }
} else {
transport = transportRef.current;
gek = gekRef.current;