Skip to content

Commit 12940df

Browse files
committed
Fix
1 parent e92811f commit 12940df

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/remoteConnector.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,9 @@ export default class RemoteConnector extends Disposable {
167167

168168
const usePublicApi = await this.experiments.getRaw<boolean>('gitpod_experimental_publicApi', session.account.id, { gitpodHost });
169169
this.logger.info(`Going to use ${usePublicApi ? 'public' : 'server'} API`);
170-
this.publicApi = new GitpodPublicApi(session.accessToken, gitpodHost, this.logger);
170+
if (usePublicApi) {
171+
this.publicApi = new GitpodPublicApi(session.accessToken, gitpodHost, this.logger);
172+
}
171173
}
172174

173175
private releaseStaleLocks(): void {

0 commit comments

Comments
 (0)