rename method

pull/108/head
Jonas Kruckenberg 3 years ago
parent 5466ed562a
commit f1ad29c882

@ -69,7 +69,7 @@ async fn set<R: Runtime>(
key: String,
value: JsonValue,
) -> Result<(), Error> {
with_store(app, stores, path, |store| store.set(key, value))
with_store(app, stores, path, |store| store.insert(key, value))
}
#[tauri::command]

@ -206,7 +206,7 @@ impl<R: Runtime> Store<R> {
Ok(())
}
pub fn set(&mut self, key: String, value: JsonValue) -> Result<(), Error> {
pub fn insert(&mut self, key: String, value: JsonValue) -> Result<(), Error> {
self.cache.insert(key.clone(), value.clone());
self.app.emit_all(
"store://change",

Loading…
Cancel
Save