Skip to content

Commit

Permalink
Re-enable service worker drive (#21)
Browse files Browse the repository at this point in the history
  • Loading branch information
martinRenou authored Jan 9, 2024
1 parent 22092e8 commit 87a2a8a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 3 additions & 4 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,9 @@ const server_kernels = kernel_specs.map(kernelspec => {
kernelspecs.register({
spec: kernelspec,
create: async (options: IKernel.IOptions): Promise<IKernel> => {
// const mountDrive = !!(
// serviceWorker?.enabled && broadcastChannel?.enabled
// );
const mountDrive = false;
const mountDrive = !!(
serviceWorker?.enabled && broadcastChannel?.enabled
);

if (mountDrive) {
console.info(
Expand Down
2 changes: 1 addition & 1 deletion src/web_worker_kernel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ export class WebWorkerKernel implements IKernel {

await this._remote.ready();

if (false || options.mountDrive) {
if (options.mountDrive) {
await this._remote.mount(driveName, '/drive', PageConfig.getBaseUrl());
await this._remote.cd(localPath);
}
Expand Down

0 comments on commit 87a2a8a

Please sign in to comment.