diff --git a/Cargo.lock b/Cargo.lock index 341329b..30e9f55 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -167,17 +167,6 @@ dependencies = [ "rand", ] -[[package]] -name = "auth" -version = "0.1.0" -dependencies = [ - "error-stack", - "futures-executor", - "reqwest", - "rs-firebase-admin-sdk", - "tracing", -] - [[package]] name = "autocfg" version = "1.1.0" @@ -2497,10 +2486,13 @@ dependencies = [ name = "service" version = "0.1.0" dependencies = [ - "auth", "chrono", "domain", + "error-stack", + "futures-executor", "library", + "reqwest", + "rs-firebase-admin-sdk", "sea-orm", "tracing", ] diff --git a/Cargo.toml b/Cargo.toml index e977d39..b22f3c4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,7 +4,7 @@ version = "0.1.0" edition = "2021" [workspace] -members = [".", "api", "auth", "domain","library", "service"] +members = [".", "api", "domain","library", "service"] # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/auth/Cargo.toml b/auth/Cargo.toml deleted file mode 100644 index 9c0bcf1..0000000 --- a/auth/Cargo.toml +++ /dev/null @@ -1,13 +0,0 @@ -[package] -name = "auth" -version = "0.1.0" -edition = "2021" - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html - -[dependencies] -rs-firebase-admin-sdk = "2.0.0" -reqwest = "0.12.4" -futures-executor = "0.3.30" -error-stack = "0.4.1" -tracing = "0.1.40" diff --git a/auth/src/lib.rs b/auth/src/lib.rs deleted file mode 100644 index a36c594..0000000 --- a/auth/src/lib.rs +++ /dev/null @@ -1 +0,0 @@ -pub mod firebase_admin; \ No newline at end of file diff --git a/service/Cargo.toml b/service/Cargo.toml index d477353..01fe772 100644 --- a/service/Cargo.toml +++ b/service/Cargo.toml @@ -9,7 +9,10 @@ edition = "2021" tracing = "0.1.40" chrono = "0.4.35" sea-orm = { version = "0.12.14", features = ["sqlx-mysql", "runtime-tokio-rustls", "macros", "debug-print"] } +rs-firebase-admin-sdk = "2.0.0" +reqwest = "0.12.4" +futures-executor = "0.3.30" +error-stack = "0.4.1" library = { path = "../library" } -domain = { path = "../domain" } -auth = { path = "../auth" } \ No newline at end of file +domain = { path = "../domain" } \ No newline at end of file diff --git a/auth/src/firebase_admin.rs b/service/src/firebase_admin.rs similarity index 100% rename from auth/src/firebase_admin.rs rename to service/src/firebase_admin.rs diff --git a/service/src/lib.rs b/service/src/lib.rs index 0ff037a..8215c76 100644 --- a/service/src/lib.rs +++ b/service/src/lib.rs @@ -1,2 +1,3 @@ pub mod player_info; pub mod feedback; +pub mod firebase_admin; diff --git a/service/src/player_info.rs b/service/src/player_info.rs index 731d6bd..e2f8bf6 100644 --- a/service/src/player_info.rs +++ b/service/src/player_info.rs @@ -5,7 +5,7 @@ use library::db; use library::resp::response::ResErr::{ErrPerm, ErrSystem}; use library::resp::response::{ResOK, ResResult}; use sea_orm::{ColumnTrait, EntityTrait, PaginatorTrait, QueryFilter, Set}; -use auth::firebase_admin; +use crate::firebase_admin; pub async fn register(req: PlayerInfoRegister) -> ResResult> { match PlayerInfo::find()