summaryrefslogtreecommitdiff
path: root/runtime
diff options
context:
space:
mode:
Diffstat (limited to 'runtime')
-rw-r--r--runtime/build.rs2
-rw-r--r--runtime/ops/web_worker/sync_fetch.rs4
-rw-r--r--runtime/web_worker.rs2
-rw-r--r--runtime/worker.rs2
4 files changed, 6 insertions, 4 deletions
diff --git a/runtime/build.rs b/runtime/build.rs
index f656682a1..e5d0067a7 100644
--- a/runtime/build.rs
+++ b/runtime/build.rs
@@ -298,7 +298,7 @@ mod startup_snapshot {
deno_console::deno_console::init_ops_and_esm(),
deno_url::deno_url::init_ops_and_esm(),
deno_web::deno_web::init_ops_and_esm::<Permissions>(
- deno_web::BlobStore::default(),
+ Default::default(),
Default::default(),
),
deno_fetch::deno_fetch::init_ops_and_esm::<Permissions>(
diff --git a/runtime/ops/web_worker/sync_fetch.rs b/runtime/ops/web_worker/sync_fetch.rs
index 4b45f5eca..4d2f4ca5a 100644
--- a/runtime/ops/web_worker/sync_fetch.rs
+++ b/runtime/ops/web_worker/sync_fetch.rs
@@ -1,5 +1,7 @@
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
+use std::sync::Arc;
+
use crate::web_worker::WebWorkerInternalHandle;
use crate::web_worker::WebWorkerType;
use deno_core::error::type_error;
@@ -46,7 +48,7 @@ pub fn op_worker_sync_fetch(
// URLs when none of the script URLs use the blob scheme.
// Also, in which contexts are blob URLs not supported?
let blob_store = state
- .try_borrow::<BlobStore>()
+ .try_borrow::<Arc<BlobStore>>()
.ok_or_else(|| type_error("Blob URLs are not supported in this context."))?
.clone();
diff --git a/runtime/web_worker.rs b/runtime/web_worker.rs
index 2dde5a369..3efc98104 100644
--- a/runtime/web_worker.rs
+++ b/runtime/web_worker.rs
@@ -343,7 +343,7 @@ pub struct WebWorkerOptions {
pub worker_type: WebWorkerType,
pub maybe_inspector_server: Option<Arc<InspectorServer>>,
pub get_error_class_fn: Option<GetErrorClassFn>,
- pub blob_store: BlobStore,
+ pub blob_store: Arc<BlobStore>,
pub broadcast_channel: InMemoryBroadcastChannel,
pub shared_array_buffer_store: Option<SharedArrayBufferStore>,
pub compiled_wasm_module_store: Option<CompiledWasmModuleStore>,
diff --git a/runtime/worker.rs b/runtime/worker.rs
index 0293c332a..20fb6db84 100644
--- a/runtime/worker.rs
+++ b/runtime/worker.rs
@@ -123,7 +123,7 @@ pub struct WorkerOptions {
pub get_error_class_fn: Option<GetErrorClassFn>,
pub cache_storage_dir: Option<std::path::PathBuf>,
pub origin_storage_dir: Option<std::path::PathBuf>,
- pub blob_store: BlobStore,
+ pub blob_store: Arc<BlobStore>,
pub broadcast_channel: InMemoryBroadcastChannel,
/// The store to use for transferring SharedArrayBuffers between isolates.