mirror of
https://github.com/redlib-org/redlib.git
synced 2025-06-08 07:37:45 +00:00
Basic subscribe functionality.
This commit is contained in:
parent
75bbcefbec
commit
345308a9ac
5 changed files with 53 additions and 11 deletions
|
@ -99,6 +99,9 @@ async fn main() -> std::io::Result<()> {
|
|||
// See posts and info about subreddit
|
||||
.route("/", web::get().to(subreddit::page))
|
||||
.route("/{sort:hot|new|top|rising|controversial}/", web::get().to(subreddit::page))
|
||||
// Handle subscribe/unsubscribe
|
||||
.route("/subscribe/", web::post().to(subreddit::subscribe))
|
||||
//.route("/unsubscribe/", web::post().to(subreddit::unsubscribe))
|
||||
// View post on subreddit
|
||||
.service(
|
||||
web::scope("/comments/{id}/{title}")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue