fix(MangaDemon): fix blurred search/home page thumbnail by hardcoding content rating#214
Conversation
|
Why not set the content rating only at where it returns the results to the app, setting content rating multiple places and changing the model seems a bit excessive |
- Site does not provide content rating - Fixes blurred search/home page thumbnail
refactored as per your suggestion. |
|
Wait no, don't overwrite the commit I made, it was ok already |
huh I didn't overwrite though? the force push is actually commit rename i did since there was a typo in it. I just moved the loops and content rating to a common function into private registerItems<T extends { mangaId?: string; contentRating?: ContentRating }>(
items: T[],
): T[] {
for (const item of items) {
if (item?.mangaId) {
this.idMap[item.mangaId.replace(/[^a-zA-Z0-9]/g, "")] = item.mangaId;
}
if (item) item.contentRating = ContentRating.EVERYONE;
}
return items;
}btw i am new to this extension development i just did this since mangademon is a source i use and the blur was annoying i am fine with any approach as long as the issue is resolved |
Summary
both home page and search page showed blurred thumbnail due to content rating not being set, paperback by default blurs unrated content. the homepage/search page doesn't have any flag to use for custom content rating so switch to hardcoded "safe" value since managdemon is not a mature.

Checklist
Making changes
For updates to existing extensions
versionvalue inpbconfig.tsfor each modified extension.For new extensions
npx paperback-cli test --generate EXTENSION_NAME.Testing changes
npm run conformancepasses.npm test -- EXTENSION_NAMEpasses.Committing changes
type(Scope): summary, e.g.fix(EXTENSION_NAME): ...).AI assistance
Pick one:
Assisted-by: AGENT_NAME:MODEL_VERSIONtrailer to each AI-assisted commit.