mirror of
https://github.com/denoland/deno.git
synced 2025-08-04 02:48:24 +00:00
feat(ops): custom arity (#13949)
Also cleanup & drop ignored wildcard op-args
This commit is contained in:
parent
9f494dc405
commit
88d0f01948
55 changed files with 99 additions and 498 deletions
|
@ -163,7 +163,6 @@ impl BlobPart for SlicedBlobPart {
|
|||
pub fn op_blob_create_part(
|
||||
state: &mut deno_core::OpState,
|
||||
data: ZeroCopyBuf,
|
||||
_: (),
|
||||
) -> Result<Uuid, AnyError> {
|
||||
let blob_store = state.borrow::<BlobStore>();
|
||||
let part = InMemoryBlobPart(data.to_vec());
|
||||
|
@ -208,7 +207,6 @@ pub fn op_blob_slice_part(
|
|||
pub async fn op_blob_read_part(
|
||||
state: Rc<RefCell<deno_core::OpState>>,
|
||||
id: Uuid,
|
||||
_: (),
|
||||
) -> Result<ZeroCopyBuf, AnyError> {
|
||||
let part = {
|
||||
let state = state.borrow();
|
||||
|
@ -224,7 +222,6 @@ pub async fn op_blob_read_part(
|
|||
pub fn op_blob_remove_part(
|
||||
state: &mut deno_core::OpState,
|
||||
id: Uuid,
|
||||
_: (),
|
||||
) -> Result<(), AnyError> {
|
||||
let blob_store = state.borrow::<BlobStore>();
|
||||
blob_store.remove_part(&id);
|
||||
|
@ -261,7 +258,6 @@ pub fn op_blob_create_object_url(
|
|||
pub fn op_blob_revoke_object_url(
|
||||
state: &mut deno_core::OpState,
|
||||
url: String,
|
||||
_: (),
|
||||
) -> Result<(), AnyError> {
|
||||
let url = Url::parse(&url)?;
|
||||
let blob_store = state.borrow::<BlobStore>();
|
||||
|
@ -285,7 +281,6 @@ pub struct ReturnBlobPart {
|
|||
pub fn op_blob_from_object_url(
|
||||
state: &mut deno_core::OpState,
|
||||
url: String,
|
||||
_: (),
|
||||
) -> Result<Option<ReturnBlob>, AnyError> {
|
||||
let url = Url::parse(&url)?;
|
||||
if url.scheme() != "blob" {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue