You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: deletescript.rs
    path of file: ./repos/mail-server/crates/managesieve/src/op
    
    the code of the file until where you have to start completion: /*
 * Copyright (c) 2020-2022, Stalwart Labs Ltd.
 *
 * This file is part of Stalwart Mail Server.
 *
 * This program is free software: you can redistribute it and/or m
    
    pub async fn handle_deletescript(&mut self, request: Request<Command>) -> super::OpResult {
        let name = request
            .tokens
            .into_iter()
            .next()
            .and_then(|s| s.unwrap_string().ok())
            .ok_or_else(|| StatusResponse::no("Expected script name as a parameter."))?;

        let account_id = self.state.access_token().primary_id();
        let document_id = self.get_script_id(account_id, &name).await?;
        if self
            .jmap
            .sieve_script_delete(account_id, document_id, true)
            .await?
        {
            // Write changes
            let mut changelog = ChangeLogBuilder::new();
            changelog.log_delete(Collection::SieveScript, document_id);
            self.jmap.commit_changes(account_id, changelog).await?;

            Ok(StatusResponse::ok("Deleted.").into_bytes())
        } else {
            Err(StatusResponse::no("You may not delete an active script")
                .with_code(ResponseCode::Active))
        }
    }