diff --git a/src/main.rs b/src/main.rs index 87a4fce..a693568 100644 --- a/src/main.rs +++ b/src/main.rs @@ -338,6 +338,14 @@ fn list( total.plurify(&["torrent", "torrents", "torrents"]) )); + if page.unwrap_or(1) * public.default_limit < total { + b.push(format!( + "=> /{}{} Next", + page.map_or(2, |p| p + 1), + query(keyword) + )) + } + if let Some(p) = page { b.push(format!( "=> {}{} Back", @@ -350,14 +358,6 @@ fn list( )) } - if page.unwrap_or(1) * public.default_limit < total { - b.push(format!( - "=> /{}{} Next", - page.map_or(2, |p| p + 1), - query(keyword) - )) - } - b.push("\n=> /search Search".into()); Ok(b.join("\n"))