mirror of
https://github.com/tauri-apps/plugins-workspace.git
synced 2026-06-06 13:53:54 +02:00
feat: Remove UNC prefix in paths returned to the frontend (#1168)
* feat: Remove UNC prefix in paths returned to the frontend * that one doesn't count * map instead of mut * revert accidental ipc::response change * move dunce to workspace root
This commit is contained in:
@@ -22,3 +22,4 @@ serde_json = { workspace = true }
|
||||
tauri = { workspace = true }
|
||||
log = { workspace = true }
|
||||
thiserror = { workspace = true }
|
||||
dunce = { workspace = true }
|
||||
@@ -58,7 +58,8 @@ impl<R: Runtime> StoreBuilder<R> {
|
||||
/// ```
|
||||
pub fn new<P: AsRef<Path>>(path: P) -> Self {
|
||||
Self {
|
||||
path: path.as_ref().to_path_buf(),
|
||||
// Since Store.path is only exposed to the user in emit calls we may as well simplify it here already.
|
||||
path: dunce::simplified(path.as_ref()).to_path_buf(),
|
||||
defaults: None,
|
||||
cache: Default::default(),
|
||||
serialize: default_serialize,
|
||||
|
||||
Reference in New Issue
Block a user