mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2024-08-30 18:12:39 +00:00
rust fmt
This commit is contained in:
@ -11,7 +11,7 @@ normalize_doc_attributes = true
|
|||||||
report_todo = "Always"
|
report_todo = "Always"
|
||||||
report_fixme = "Always"
|
report_fixme = "Always"
|
||||||
imports_layout = "HorizontalVertical"
|
imports_layout = "HorizontalVertical"
|
||||||
merge_imports = true
|
imports_granularity = "Crate"
|
||||||
reorder_modules = true
|
reorder_modules = true
|
||||||
reorder_imports = true
|
reorder_imports = true
|
||||||
enum_discrim_align_threshold = 20
|
enum_discrim_align_threshold = 20
|
||||||
|
@ -64,8 +64,7 @@ pub fn get_configuration() -> Result<Settings, config::ConfigError> {
|
|||||||
.try_into()
|
.try_into()
|
||||||
.expect("Failed to parse APP_ENVIRONMENT.");
|
.expect("Failed to parse APP_ENVIRONMENT.");
|
||||||
|
|
||||||
settings
|
settings.merge(config::File::from(configuration_dir.join(environment.as_str())).required(true))?;
|
||||||
.merge(config::File::from(configuration_dir.join(environment.as_str())).required(true))?;
|
|
||||||
|
|
||||||
// Add in settings from environment variables (with a prefix of APP and '__' as
|
// Add in settings from environment variables (with a prefix of APP and '__' as
|
||||||
// separator) E.g. `APP_APPLICATION__PORT=5001 would set
|
// separator) E.g. `APP_APPLICATION__PORT=5001 would set
|
||||||
|
@ -8,7 +8,8 @@ use backend_service::{
|
|||||||
errors::{invalid_params, ErrorCode, ServerError},
|
errors::{invalid_params, ErrorCode, ServerError},
|
||||||
response::FlowyResponse,
|
response::FlowyResponse,
|
||||||
};
|
};
|
||||||
|
#[allow(dead_code)]
|
||||||
|
use chrono::Utc;
|
||||||
use flowy_user_infra::{
|
use flowy_user_infra::{
|
||||||
parser::{UserEmail, UserName, UserPassword},
|
parser::{UserEmail, UserName, UserPassword},
|
||||||
protobuf::{SignInParams, SignInResponse, SignUpParams, SignUpResponse, UpdateUserParams, UserProfile},
|
protobuf::{SignInParams, SignInResponse, SignUpParams, SignUpResponse, UpdateUserParams, UserProfile},
|
||||||
|
@ -11,7 +11,7 @@ normalize_doc_attributes = true
|
|||||||
report_todo = "Always"
|
report_todo = "Always"
|
||||||
report_fixme = "Always"
|
report_fixme = "Always"
|
||||||
imports_layout = "HorizontalVertical"
|
imports_layout = "HorizontalVertical"
|
||||||
merge_imports = true
|
imports_granularity = "Crate"
|
||||||
reorder_modules = true
|
reorder_modules = true
|
||||||
reorder_imports = true
|
reorder_imports = true
|
||||||
enum_discrim_align_threshold = 20
|
enum_discrim_align_threshold = 20
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
#[rustfmt::skip]
|
||||||
pub enum TypeCategory {
|
pub enum TypeCategory {
|
||||||
Array,
|
Array,
|
||||||
Map,
|
Map,
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
#[rustfmt::skip]
|
||||||
pub enum TypeCategory {
|
pub enum TypeCategory {
|
||||||
Array,
|
Array,
|
||||||
Map,
|
Map,
|
||||||
@ -76,8 +77,7 @@ pub fn category_from_str(type_str: &str) -> TypeCategory {
|
|||||||
| "UserToken"
|
| "UserToken"
|
||||||
| "UserProfile"
|
| "UserProfile"
|
||||||
| "UpdateUserRequest"
|
| "UpdateUserRequest"
|
||||||
| "UpdateUserParams"
|
| "UpdateUserParams" => TypeCategory::Protobuf,
|
||||||
=> TypeCategory::Protobuf,
|
|
||||||
"WorkspaceEvent"
|
"WorkspaceEvent"
|
||||||
| "WorkspaceNotification"
|
| "WorkspaceNotification"
|
||||||
| "ErrorCode"
|
| "ErrorCode"
|
||||||
@ -90,8 +90,7 @@ pub fn category_from_str(type_str: &str) -> TypeCategory {
|
|||||||
| "ExportType"
|
| "ExportType"
|
||||||
| "RevType"
|
| "RevType"
|
||||||
| "WsDataType"
|
| "WsDataType"
|
||||||
| "WsModule"
|
| "WsModule" => TypeCategory::Enum,
|
||||||
=> TypeCategory::Enum,
|
|
||||||
|
|
||||||
"Option" => TypeCategory::Opt,
|
"Option" => TypeCategory::Opt,
|
||||||
_ => TypeCategory::Primitive,
|
_ => TypeCategory::Primitive,
|
||||||
|
@ -11,7 +11,7 @@ normalize_doc_attributes = true
|
|||||||
report_todo = "Always"
|
report_todo = "Always"
|
||||||
report_fixme = "Always"
|
report_fixme = "Always"
|
||||||
imports_layout = "HorizontalVertical"
|
imports_layout = "HorizontalVertical"
|
||||||
merge_imports = true
|
imports_granularity = "Crate"
|
||||||
reorder_modules = true
|
reorder_modules = true
|
||||||
reorder_imports = true
|
reorder_imports = true
|
||||||
enum_discrim_align_threshold = 20
|
enum_discrim_align_threshold = 20
|
||||||
|
Reference in New Issue
Block a user