Skip to content

Commit

Permalink
fix(acl): scope resolution should be per window (#9068)
Browse files Browse the repository at this point in the history
* fix(acl): scope resolution should be per window

* Update core/tauri-utils/src/acl/resolved.rs

Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>

* update snapshots

* lint

---------

Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
  • Loading branch information
lucasfernog and amrbashir authored Mar 4, 2024
1 parent 9aa0d6e commit 6c06832
Show file tree
Hide file tree
Showing 23 changed files with 1,460 additions and 986 deletions.
6 changes: 6 additions & 0 deletions .changes/fix-scope-resolution.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"tauri": patch:bug
"tauri-utils": patch:bug
---

Fixes scope resolution grouping scopes for all windows.
5 changes: 5 additions & 0 deletions .changes/refactor-scope-ret-value.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"tauri": patch:breaking
---

The `allows` and `denies` methods from `ipc::ScopeValue`, `ipc::CommandScope` and `ipc::GlobalScope` now returns `&Vec<Arc<T>>` instead of `&Vec<T>`.
3 changes: 2 additions & 1 deletion core/tauri-utils/src/acl/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -205,9 +205,10 @@ pub struct PermissionSet {
}

/// Execution context of an IPC call.
#[derive(Debug, Clone, Eq, PartialEq, PartialOrd, Ord, Hash)]
#[derive(Debug, Default, Clone, Eq, PartialEq, PartialOrd, Ord, Hash)]
pub enum ExecutionContext {
/// A local URL is used (the Tauri app URL).
#[default]
Local,
/// Remote URL is tring to use the IPC.
Remote {
Expand Down
Loading

0 comments on commit 6c06832

Please sign in to comment.