Skip to content

Commit d2eaefd

Browse files
committed
Check that JS API from server support remote file source service (DH-20578)
1 parent e92d180 commit d2eaefd

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/dh/dhc.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,9 @@ export async function initDhcSession(
157157
type === 'python' ? await getRemoteFileSourcePlugin(cnId, session) : null;
158158

159159
const groovyRemoteFileSourcePlugin: DhType.remotefilesource.RemoteFileSourceService | null =
160-
type === 'groovy' ? await client.getRemoteFileSourceService() : null;
160+
type === 'groovy' && 'getRemoteFileSourceService' in client
161+
? await client.getRemoteFileSourceService()
162+
: null;
161163

162164
return {
163165
cn,

0 commit comments

Comments
 (0)