mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2024-08-30 18:12:39 +00:00
feat: custom server url in application (#3996)
* chore:test * chore: update ui * feat: set appflowy cloud url * chore: add self host docs * fix: save user * fix: sign out when authenticator not match * fix: sign out when authenticator not match * fix: db lock * chore: remove unuse env file * test: disable supabase cloud test * test: disable supabase cloud test * chore: fix save
This commit is contained in:
@ -27,6 +27,7 @@ r2d2 = { version = "0.8", optional = true }
|
||||
url = { version = "2.2", optional = true }
|
||||
collab-database = { version = "0.1.0", optional = true }
|
||||
collab-document = { version = "0.1.0", optional = true }
|
||||
collab-persistence = { version = "0.1.0", optional = true }
|
||||
tokio-postgres = { version = "0.7.8", optional = true }
|
||||
client-api = { version = "0.1.0", optional = true }
|
||||
|
||||
@ -36,7 +37,7 @@ impl_from_dispatch_error = ["lib-dispatch"]
|
||||
impl_from_serde = []
|
||||
impl_from_reqwest = ["reqwest"]
|
||||
impl_from_sqlite = ["flowy-sqlite", "r2d2"]
|
||||
impl_from_collab = ["collab-database", "collab-document", "impl_from_reqwest"]
|
||||
impl_from_collab = ["collab-database", "collab-document", "impl_from_reqwest", "collab-persistence"]
|
||||
impl_from_postgres = ["tokio-postgres"]
|
||||
impl_from_url = ["url"]
|
||||
impl_from_appflowy_cloud = ["client-api"]
|
||||
|
@ -1,8 +1,18 @@
|
||||
use collab_database::error::DatabaseError;
|
||||
use collab_document::error::DocumentError;
|
||||
use collab_persistence::PersistenceError;
|
||||
|
||||
use crate::FlowyError;
|
||||
use crate::{ErrorCode, FlowyError};
|
||||
|
||||
impl From<PersistenceError> for FlowyError {
|
||||
fn from(err: PersistenceError) -> Self {
|
||||
match err {
|
||||
PersistenceError::RocksdbCorruption(_) => FlowyError::new(ErrorCode::RocksdbCorruption, err),
|
||||
PersistenceError::RocksdbIOError(_) => FlowyError::new(ErrorCode::RocksdbIOError, err),
|
||||
_ => FlowyError::new(ErrorCode::RocksdbInternal, err),
|
||||
}
|
||||
}
|
||||
}
|
||||
impl From<DatabaseError> for FlowyError {
|
||||
fn from(error: DatabaseError) -> Self {
|
||||
FlowyError::internal().with_context(error)
|
||||
|
Reference in New Issue
Block a user