cleanup WorkerTaskContext

This commit is contained in:
Dietmar Maurer
2021-09-24 11:39:30 +02:00
parent 1ec0d70d09
commit 619cd5cbcb
5 changed files with 25 additions and 23 deletions

View File

@ -30,13 +30,12 @@ use proxmox::{
use pbs_api_types::{VirtualTapeDrive, LtoTapeDrive, Fingerprint};
use pbs_config::key_config::KeyConfig;
use pbs_tools::task_log;
use pbs_tools::{task_log, task::WorkerTaskContext};
use pbs_tape::{
TapeWrite, TapeRead, BlockReadError, MediaContentHeader,
sg_tape::TapeAlertFlags,
};
use proxmox_rest_server::WorkerTask;
use crate::{
server::send_load_media_email,
@ -355,7 +354,7 @@ impl std::fmt::Display for TapeRequestError {
///
/// Returns a handle to the opened drive and the media labels.
pub fn request_and_load_media(
worker: &WorkerTask,
worker: &dyn WorkerTaskContext,
config: &SectionConfigData,
drive: &str,
label: &MediaLabel,