foundation: fix foundation.app/@name/~/$id type URLs.
Fix URLs like this not working:
https://foundation.app/@mochiiimo/~/97376
The correct URL is now:
https://foundation.app/@mochiiimo/foundation/97376
This commit is contained in:
@@ -30,6 +30,11 @@ class Source::URL::Foundation < Source::URL
|
|||||||
@user_id = user_id
|
@user_id = user_id
|
||||||
|
|
||||||
# https://foundation.app/@mochiiimo/~/97376
|
# https://foundation.app/@mochiiimo/~/97376
|
||||||
|
in "foundation.app", /^@/ => username, "~", /^\d+/ => work_id
|
||||||
|
@username = username.delete_prefix("@")
|
||||||
|
@collection = "foundation"
|
||||||
|
@work_id = work_id
|
||||||
|
|
||||||
# https://foundation.app/@mochiiimo/foundation/97376
|
# https://foundation.app/@mochiiimo/foundation/97376
|
||||||
# https://foundation.app/@KILLERGF/kgfgen/4
|
# https://foundation.app/@KILLERGF/kgfgen/4
|
||||||
in "foundation.app", /^@/ => username, collection, /^\d+/ => work_id
|
in "foundation.app", /^@/ => username, collection, /^\d+/ => work_id
|
||||||
|
|||||||
Reference in New Issue
Block a user