Skip to content

Fix MangaUpdates WebLink to handle new url format#209

Merged
Snd-R merged 2 commits intomasterfrom
unknown repository
Mar 16, 2025
Merged

Fix MangaUpdates WebLink to handle new url format#209
Snd-R merged 2 commits intomasterfrom
unknown repository

Conversation

@ghost
Copy link

@ghost ghost commented Mar 15, 2025

This pull request updates the logic used while adding aggregated MangaUpdates links to support both the existing series.html?id={numeric_id} format (for both old and new numeric ids, this page redirects to series/) and the newer series/{hex_id} format (this alphanumeric id is hex encoded version of the new long numeric ids).

I removed encodeURLPath, which was unnecessarily encoding the ? character in series.html?id= part. Also id parameter in the old series.html url only accepts numeric ids.

Example valid URLs

  • https://www.mangaupdates.com/series/qzqpezy
  • https://www.mangaupdates.com/series.html?id=58757512750

How Komf added the urls before this change:

  • https://www.mangaupdates.com/series.html%3Fid=qzqpezy

@ghost
Copy link
Author

ghost commented Mar 15, 2025

looks like encodeURLPath also breaks comic.naver.com and webtoons.com urls in the lines below by encoding the ? character but I'm not sure if removing it would break things for other possible urls from mangadex:

"raw" -> links[RAW] = WebLink("Official Raw", value.encodeURLPath())
"engtl" -> links[ENGLISH_TL] = WebLink("Official English", value.encodeURLPath())

@Snd-R
Copy link
Owner

Snd-R commented Mar 16, 2025

Thanks for looking into this.
I've also fixed other potential problematic urls with parseUrl method where value could be full url or is made of multiple url paths

@Snd-R Snd-R merged commit 07eebc0 into Snd-R:master Mar 16, 2025
@ghost ghost deleted the fix-mangaupdates-url-format branch March 16, 2025 12:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant