Done first draft of strongly typed migrations
This commit is contained in:
@@ -11,7 +11,7 @@ use async_tungstenite::tungstenite::{
|
||||
error::Error as WebsocketError,
|
||||
http::{Request, StatusCode},
|
||||
};
|
||||
use db::Db;
|
||||
use db::{kvp::KeyValue, Db};
|
||||
use futures::{future::LocalBoxFuture, AsyncReadExt, FutureExt, SinkExt, StreamExt, TryStreamExt};
|
||||
use gpui::{
|
||||
actions,
|
||||
@@ -1218,7 +1218,7 @@ impl Client {
|
||||
self.peer.respond_with_error(receipt, error)
|
||||
}
|
||||
|
||||
pub fn start_telemetry(&self, db: Db) {
|
||||
pub fn start_telemetry(&self, db: Db<KeyValue>) {
|
||||
self.telemetry.start(db.clone());
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
use crate::http::HttpClient;
|
||||
use db::Db;
|
||||
use db::{kvp::KeyValue, Db};
|
||||
use gpui::{
|
||||
executor::Background,
|
||||
serde_json::{self, value::Map, Value},
|
||||
@@ -148,7 +148,7 @@ impl Telemetry {
|
||||
Some(self.state.lock().log_file.as_ref()?.path().to_path_buf())
|
||||
}
|
||||
|
||||
pub fn start(self: &Arc<Self>, db: Db) {
|
||||
pub fn start(self: &Arc<Self>, db: Db<KeyValue>) {
|
||||
let this = self.clone();
|
||||
self.executor
|
||||
.spawn(
|
||||
|
||||
Reference in New Issue
Block a user