fix: wrong type passed when passing path by ref

pull/455/head
OrIOg 2 years ago
parent ecfac38841
commit e95398f2ab
No known key found for this signature in database
GPG Key ID: ADB1356088AFB1E5

@ -160,18 +160,18 @@ pub fn init<R: Runtime>() -> TauriPlugin<R> {
.unwrap_or_default();
for allowed in &scope.allowed_paths {
let allowed = fix_pattern(&ac, allowed);
let allowed = fix_pattern(&ac, &allowed);
allow_path(&fs_scope, &allowed);
#[cfg(feature = "protocol-asset")]
allow_path(&asset_protocol_scope, allowed);
allow_path(&asset_protocol_scope, &allowed);
}
for forbidden in &scope.forbidden_patterns {
let forbidden = fix_pattern(&ac, forbidden);
let forbidden = fix_pattern(&ac, &forbidden);
forbid_path(&fs_scope, &forbidden);
#[cfg(feature = "protocol-asset")]
forbid_path(&asset_protocol_scope, forbidden);
forbid_path(&asset_protocol_scope, &forbidden);
}
// Manually save the fixed scopes to disk once.

Loading…
Cancel
Save