chore: format with cargo fix
This commit is contained in:
parent
0290f4d2e7
commit
e6c3cacf12
@ -57,11 +57,11 @@ pub fn Posts() -> Element {
|
||||
Ok(CreatePostResponse { success: true, .. }) => {
|
||||
posts_res.restart();
|
||||
}
|
||||
Ok(CreatePostResponse { success: false, message, .. }) => {
|
||||
Ok(CreatePostResponse { success: false, message: _, .. }) => {
|
||||
#[cfg(target_arch = "wasm32")]
|
||||
web_sys::window().map(|w| w.alert_with_message(&message).ok());
|
||||
}
|
||||
Err(e) => {
|
||||
Err(_e) => {
|
||||
#[cfg(target_arch = "wasm32")]
|
||||
web_sys::window().map(|w| w.alert_with_message(&format!("删除失败: {}", e)).ok());
|
||||
}
|
||||
|
||||
@ -3,7 +3,6 @@ use dioxus::prelude::*;
|
||||
#[cfg(target_arch = "wasm32")]
|
||||
use wasm_bindgen::JsCast;
|
||||
|
||||
use crate::api::posts::{create_post, CreatePostResponse};
|
||||
use crate::components::write_skeleton::WriteSkeleton;
|
||||
|
||||
#[component]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user