mirror of
https://codeberg.org/VnPower/PixivFE
synced 2024-12-06 19:16:23 +01:00
Add support for legacy artwork URL
This commit is contained in:
+7
-2
@@ -47,8 +47,8 @@ func SetupRoutes(r *fiber.App) {
|
||||
})
|
||||
|
||||
r.Get("/", index_page)
|
||||
r.Get("/about", about_page)
|
||||
r.Get("artworks/:id/", limit, artwork_page)
|
||||
r.Get("about", about_page)
|
||||
r.Get("artworks/:id/", limit, artwork_page).Name("artworks")
|
||||
r.Get("users/:id/:category?", user_page)
|
||||
r.Get("newest", newest_artworks_page)
|
||||
r.Get("ranking", ranking_page)
|
||||
@@ -67,6 +67,11 @@ func SetupRoutes(r *fiber.App) {
|
||||
settings.Get("/", settings_page)
|
||||
settings.Post("/:type", settings_post)
|
||||
|
||||
// Legacy illust URL
|
||||
r.Get("member_illust.php", func(c *fiber.Ctx) error {
|
||||
return c.Redirect("artworks/" + c.Query("illust_id"))
|
||||
})
|
||||
|
||||
// 404 page
|
||||
// r.NoRoute(not_found_page)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user