fix(error): perf error
This commit is contained in:
@@ -113,7 +113,7 @@ common-telemetry = { git = "ssh://git@gitea.shay7sev.site:2222/admin/common-tele
|
||||
#### A. 初始化日志 (main.rs)
|
||||
|
||||
```rust
|
||||
use common_lib::telemetry::{self, TelemetryConfig};
|
||||
use common_telemetry::telemetry::{self, TelemetryConfig};
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() {
|
||||
@@ -141,7 +141,7 @@ async fn main() {
|
||||
|
||||
```rust
|
||||
use axum::{Json, response::IntoResponse};
|
||||
use common_lib::AppError; // 引入统一错误
|
||||
use common_telemetry::AppError; // 引入统一错误
|
||||
|
||||
async fn get_profile(token: String) -> Result<Json<UserProfile>, AppError> {
|
||||
// 模拟:Token 过期
|
||||
|
||||
Reference in New Issue
Block a user