diff options
author | metamuffin <metamuffin@disroot.org> | 2025-04-29 11:10:21 +0200 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2025-04-29 11:10:21 +0200 |
commit | f62c7f2a8cc143454779dc99334ca9fc80ddabd5 (patch) | |
tree | f31dbb908715d2deb2860e2097fa13dd41d759d5 /server/src/logic/userdata.rs | |
parent | 73d2d5eb01fceae9e0b1c58afb648822000c878a (diff) | |
download | jellything-f62c7f2a8cc143454779dc99334ca9fc80ddabd5.tar jellything-f62c7f2a8cc143454779dc99334ca9fc80ddabd5.tar.bz2 jellything-f62c7f2a8cc143454779dc99334ca9fc80ddabd5.tar.zst |
still just moving code around
Diffstat (limited to 'server/src/logic/userdata.rs')
-rw-r--r-- | server/src/logic/userdata.rs | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/server/src/logic/userdata.rs b/server/src/logic/userdata.rs index 64a136f..8da6be9 100644 --- a/server/src/logic/userdata.rs +++ b/server/src/logic/userdata.rs @@ -3,19 +3,17 @@ which is licensed under the GNU Affero General Public License (version 3); see /COPYING. Copyright (C) 2025 metamuffin <metamuffin.org> */ -use crate::{ui::error::MyResult, ui::node::rocket_uri_macro_r_library_node}; +use crate::ui::error::MyResult; use jellybase::database::Database; use jellycommon::{ - user::{NodeUserData, WatchedState}, - NodeID, + routes::u_node_id, user::{NodeUserData, WatchedState}, NodeID }; +use jellylogic::session::Session; use rocket::{ form::Form, get, post, response::Redirect, serde::json::Json, FromForm, FromFormField, State, UriDisplayQuery, }; -use super::session::Session; - #[derive(Debug, FromFormField, UriDisplayQuery)] pub enum UrlWatchedState { None, @@ -51,7 +49,7 @@ pub async fn r_node_userdata_watched( }; Ok(()) })?; - Ok(Redirect::found(rocket::uri!(r_library_node(id)))) + Ok(Redirect::found(u_node_id(id))) } #[derive(FromForm)] @@ -72,7 +70,7 @@ pub async fn r_node_userdata_rating( udata.rating = form.rating; Ok(()) })?; - Ok(Redirect::found(rocket::uri!(r_library_node(id)))) + Ok(Redirect::found(u_node_id(id))) } #[post("/n/<id>/progress?<t>")] |