Skip to content

Commit d1a6e2f

Browse files
authored
chore(deps): update state to 0.6 (#7252)
1 parent 7036bc9 commit d1a6e2f

File tree

3 files changed

+9
-4
lines changed

3 files changed

+9
-4
lines changed

.changes/state-0.6.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"tauri": patch:deps
3+
---
4+
5+
Update `state` to v0.6.

core/tauri/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ tauri-runtime-wry = { version = "0.13.0-alpha.6", path = "../tauri-runtime-wry",
5454
rand = "0.8"
5555
semver = { version = "1.0", features = [ "serde" ] }
5656
serde_repr = "0.1"
57-
state = "0.5"
57+
state = "0.6"
5858
tempfile = "3"
5959
http = "0.2"
6060
dirs-next = "2.0"

core/tauri/src/state.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use crate::{
66
command::{CommandArg, CommandItem},
77
InvokeError, Runtime,
88
};
9-
use state::Container;
9+
use state::TypeMap;
1010

1111
/// A guard for a state value.
1212
///
@@ -58,11 +58,11 @@ impl<'r, 'de: 'r, T: Send + Sync + 'static, R: Runtime> CommandArg<'de, R> for S
5858

5959
/// The Tauri state manager.
6060
#[derive(Debug)]
61-
pub struct StateManager(pub(crate) Container![Send + Sync]);
61+
pub struct StateManager(pub(crate) TypeMap![Send + Sync]);
6262

6363
impl StateManager {
6464
pub(crate) fn new() -> Self {
65-
Self(<Container![Send + Sync]>::new())
65+
Self(<TypeMap![Send + Sync]>::new())
6666
}
6767

6868
pub(crate) fn set<T: Send + Sync + 'static>(&self, state: T) -> bool {

0 commit comments

Comments
 (0)