From baaee5cf2177cf5c15d06421994853bf1eff96ca Mon Sep 17 00:00:00 2001 From: arkon Date: Sat, 11 Feb 2023 14:21:03 -0500 Subject: [PATCH] Update linter (#15317) --- .editorconfig | 2 + common.gradle | 8 + gradle/libs.versions.toml | 2 +- .../manhuamanganet/src/ManhuaMangaNet.kt | 2 +- .../manhwamanganet/src/ManhwaMangaNet.kt | 2 +- .../bakamanga/manhwaxxl/src/ManhwaXXL.kt | 2 +- .../bakamanga/mwmanhwa/src/MWManhwa.kt | 2 +- .../src/BilibiliComicsFactory.kt | 16 +- .../bilibilimanga/src/BilibiliManga.kt | 4 +- .../overrides/eromuse/erofus/src/Erofus.kt | 4 +- .../overrides/fmreader/mangatr/src/MangaTR.kt | 1 + .../fmreader/manhwa18/src/Manhwa18.kt | 2 +- .../fmreader/rawlh/src/WeLoveManga.kt | 1 + .../lecercleduscan/src/LeCercleDuScan.kt | 2 +- .../gattsu/hentaiseason/src/HentaiSeason.kt | 2 +- .../gattsu/hentaitokyo/src/HentaiTokyo.kt | 2 +- .../universohentai/src/UniversoHentai.kt | 2 +- .../gigaviewer/comicdays/src/ComicDays.kt | 4 +- .../gigaviewer/comicgardo/src/ComicGardo.kt | 4 +- .../gigaviewer/comiplex/src/Comiplex.kt | 4 +- .../corocoroonline/src/CorocoroOnline.kt | 2 +- .../gigaviewer/kuragebunch/src/KurageBunch.kt | 4 +- .../magazinepocket/src/MagazinePocket.kt | 4 +- .../gigaviewer/magcomi/src/MagComi.kt | 4 +- .../shonenjumpplus/src/ShonenJumpPlus.kt | 4 +- .../sundaywebevery/src/SundayWebEvery.kt | 4 +- .../src/TonariNoYoungJump.kt | 4 +- .../grouple/allhentai/src/AllHentai.kt | 18 +- .../grouple/mintmanga/src/MintManga.kt | 20 ++- .../grouple/readmanga/src/ReadManga.kt | 20 ++- multisrc/overrides/grouple/rumix/src/RuMIX.kt | 10 +- .../grouple/selfmanga/src/SelfManga.kt | 14 +- .../src/MagicalTranslators.kt | 6 +- .../heancms/reaperscans/src/ReaperScans.kt | 4 +- .../heancms/yugenmangas/src/YugenMangas.kt | 4 +- .../libgroup/hentailib/src/HentaiLib.kt | 4 +- .../libgroup/mangalib/src/MangaLib.kt | 8 +- .../overrides/libgroup/yaoilib/src/YaoiLib.kt | 8 +- .../madara/adultwebtoon/src/AdultWebtoon.kt | 4 +- .../madara/aiyumanga/src/AiYuManga.kt | 2 +- .../madara/akumanotenshi/src/AkumaNoTenshi.kt | 2 +- .../madara/aleatoriascan/src/AleatoriaScan.kt | 2 +- multisrc/overrides/madara/amuy/src/Amuy.kt | 4 +- .../madara/arabtoons/src/ArabToons.kt | 2 +- .../madara/arthurscan/src/ArthurScan.kt | 2 +- .../bananamecanica/src/BananaCitrica.kt | 2 +- .../bichentraducoes/src/BichenTraducoes.kt | 2 +- .../madara/blmanhwaclub/src/BlManhwaClub.kt | 2 +- .../borutoexplorer/src/BorutoExplorer.kt | 2 +- .../madara/cafecomyaoi/src/CafeComYaoi.kt | 2 +- .../madara/cattranslator/src/CatTranslator.kt | 2 +- .../madara/cerisescans/src/CeriseScans.kt | 4 +- .../src/ChunchunmaruTranslations.kt | 2 +- .../madara/cronosscan/src/CronosScan.kt | 2 +- .../overrides/madara/daprob/src/DapRob.kt | 2 +- .../madara/doujinhentai/src/DoujinHentai.kt | 8 +- .../madara/dropescan/src/DropeScan.kt | 2 +- .../overrides/madara/egymanga/src/EGYManga.kt | 2 +- .../overrides/madara/eromiau/src/Eromiau.kt | 2 +- .../estufadecristal/src/EstufaDeCristal.kt | 2 +- .../overrides/madara/evascans/src/EvaScans.kt | 2 +- .../overrides/madara/faestorm/src/FaeStorm.kt | 2 +- .../overrides/madara/fayscans/src/FayScans.kt | 2 +- .../overrides/madara/fdmscan/src/FDMScan.kt | 2 +- .../madara/finalscans/src/FinalScans.kt | 2 +- .../firstkissmanga/src/FirstKissManga.kt | 2 +- .../src/FirstKissMangaClub.kt | 2 +- .../src/FirstKissMangaLove.kt | 2 +- .../firstkissmanhua/src/FirstKissManhua.kt | 2 +- .../madara/fleurblanche/src/FleurBlanche.kt | 2 +- .../madara/flextapescans/src/FlexTapeScans.kt | 2 +- .../overrides/madara/foxwhite/src/FoxWhite.kt | 2 +- .../fukushuunoyuusha/src/FukushuunoYuusha.kt | 6 +- .../madara/furioscans/src/FurioScans.kt | 2 +- .../madara/geasstoon/src/GeassToon.kt | 2 +- .../madara/geceninlordu/src/GeceninLordu.kt | 2 +- .../madara/gloriousscan/src/GloriousScan.kt | 2 +- .../madara/glorymanga/src/GloryManga.kt | 2 +- .../madara/gloryscans/src/GloryScans.kt | 2 +- .../madara/gooffansub/src/GoofFansub.kt | 2 +- .../madara/hattorimanga/src/HattoriManga.kt | 2 +- .../overrides/madara/helascan/src/HelaScan.kt | 2 +- .../madara/hentaicube/src/HentaiCB.kt | 4 +- .../madara/hentaimanga/src/HentaiManga.kt | 2 +- .../madara/hentairead/src/Hentairead.kt | 4 +- .../madara/hentaiteca/src/HentaiTeca.kt | 2 +- .../madara/hentaixcomic/src/HentaiXComic.kt | 2 +- .../madara/hentaixyuri/src/HentaiXYuri.kt | 2 +- .../madara/herenscan/src/HerenScan.kt | 2 +- multisrc/overrides/madara/hm2d/src/HM2D.kt | 2 +- .../overrides/madara/hmanhwa/src/hManhwa.kt | 2 +- .../src/IchirinNoHanaYuri.kt | 2 +- .../madara/illusionscan/src/IllusionScan.kt | 2 +- .../immortalupdates/src/ImmortalUpdates.kt | 8 +- .../src/ImperioDaBritannia.kt | 2 +- .../madara/imperioscans/src/ImperioScans.kt | 2 +- .../overrides/madara/izakaya/src/Izakaya.kt | 2 +- .../jaiminisboxnet/src/Jaiminisboxnet.kt | 2 +- .../madara/kalangoscan/src/KalangoScan.kt | 2 +- .../kamisamaexplorer/src/KamiSamaExplorer.kt | 2 +- .../madara/laramanga/src/LaraManga.kt | 2 +- .../madara/limascans/src/LimaScans.kt | 2 +- .../madara/lordmanga/src/LordManga.kt | 2 +- .../madara/madaradex/src/MadaraDex.kt | 2 +- .../madara/manga18fx/src/Manga18fx.kt | 10 +- .../madara/manga3asq/src/Manga3asq.kt | 2 +- .../madara/manga4all/src/Manga4All.kt | 2 +- .../madara/mangabilgini/src/MangaBilgini.kt | 2 +- .../madara/mangaclash/src/MangaClash.kt | 2 +- .../madara/mangadistrict/src/MangaDistrict.kt | 2 +- .../madara/mangafastcom/src/Mangafastcom.kt | 2 +- .../madara/mangafenix/src/MangaFenix.kt | 2 +- .../mangaforfree/src/MangaForFreeFactory.kt | 2 +- .../mangafreakonline/src/MangaFreakOnline.kt | 2 +- .../madara/mangakeyfi/src/MangaKeyfi.kt | 2 +- .../overrides/madara/mangakio/src/MangaKio.kt | 2 +- .../madara/mangakomi/src/MangaKomi.kt | 2 +- .../overrides/madara/mangame/src/MangaMe.kt | 2 +- .../overrides/madara/mangapt/src/MangaPT.kt | 2 +- .../madara/mangaqueen/src/MangaQueen.kt | 2 +- .../madara/mangasehri/src/MangaSehri.kt | 2 +- .../madara/mangasepeti/src/MangaSepeti.kt | 2 +- .../madara/mangasoverall/src/RogMangas.kt | 2 +- .../src/Mangatxunoriginal.kt | 2 +- .../madara/mangauptocats/src/Mangauptocats.kt | 2 +- .../overrides/madara/manhuaes/src/ManhuaES.kt | 2 +- .../madara/manhuazone/src/ManhuaZone.kt | 2 +- .../manhwa18cc/src/Manhwa18CcFactory.kt | 2 +- .../madara/manhwa365/src/Manhwa365.kt | 2 +- .../overrides/madara/manhwa68/src/Manhwa68.kt | 2 +- .../madara/manhwadashraw/src/ManhwaDashRaw.kt | 2 +- .../madara/manhwafull/src/Manhwafull.kt | 4 +- .../overrides/madara/mhentais/src/MHentais.kt | 2 +- .../madara/minitwoscan/src/MiniTwoScan.kt | 2 +- .../miradscanlator/src/MiradScanlator.kt | 2 +- .../madara/mizumangas/src/MizuMangas.kt | 2 +- .../momonohanascan/src/MomoNoHanaScan.kt | 2 +- .../madara/monarcamanga/src/MonarcaManga.kt | 2 +- .../madara/mryaoifansub/src/MrYaoiFansub.kt | 2 +- .../src/MyUniverseScanlator.kt | 2 +- .../nekobreakerscan/src/NekoBreakerScan.kt | 2 +- .../madara/ninjascan/src/NinjaScan.kt | 2 +- .../src/NoblesseTranslations.kt | 2 +- .../src/OlympusScanlationFactory.kt | 6 +- .../olympusscantop/src/OlympusScanTop.kt | 2 +- .../madara/pirulitorosa/src/PirulitoRosa.kt | 2 +- .../madara/pojokmanga/src/PojokManga.kt | 6 +- .../madara/portalyaoi/src/PortalYaoi.kt | 2 +- .../madara/prismahentais/src/PrismaHentais.kt | 2 +- .../madara/prismascans/src/PrismaScans.kt | 2 +- .../projetoscanlator/src/ProjetoScanlator.kt | 2 +- .../rainbowfairyscan/src/RainbowFairyScan.kt | 2 +- .../madara/randomscan/src/RandomScan.kt | 2 +- .../madara/readmanhua/src/ReadManhua.kt | 2 +- .../reaperscans/src/ReaperScansFactory.kt | 8 +- .../overrides/madara/remangas/src/Remangas.kt | 2 +- .../madara/romantikmanga/src/RomantikManga.kt | 2 +- .../overrides/madara/rwbyscan/src/RwbyScan.kt | 2 +- .../scambertraslator/src/ScamberTraslator.kt | 2 +- .../madara/sensainayuri/src/SensainaYuri.kt | 2 +- .../overrides/madara/shayami/src/Shayami.kt | 2 +- .../madara/shinzooscan/src/ShinzooScan.kt | 2 +- .../madara/shiraiscans/src/ShiraiScans.kt | 2 +- .../madara/sinensis/src/SinensisScan.kt | 2 +- .../overrides/madara/sodascan/src/SodaScan.kt | 2 +- .../sweetdesirescan/src/SweetDesireScan.kt | 2 +- .../madara/sweettimescan/src/SweetTimeScan.kt | 2 +- .../madara/tatakaescan/src/TatakaeScan.kt | 2 +- .../madara/taurusfansub/src/TaurusFansub.kt | 2 +- .../madara/teenmanhua/src/TeenManhua.kt | 2 +- .../overrides/madara/thesugar/src/TheSugar.kt | 2 +- .../src/ThreeQueensScanlator.kt | 2 +- .../madara/tonizutoon/src/TonizuToon.kt | 2 +- .../overrides/madara/toonily/src/Toonily.kt | 2 +- .../madara/tortugaceviri/src/TortugaCeviri.kt | 2 +- .../madara/treemanga/src/TreeManga.kt | 2 +- .../tudoquadrinhos/src/TudoQuadrinhos.kt | 2 +- .../madara/vermanhwas/src/VerManhwas.kt | 2 +- .../madara/visbellum/src/Visbellum.kt | 2 +- .../madara/warqueenscan/src/WarQueenScan.kt | 2 +- .../madara/webtoonstop/src/WebtoonsTOP.kt | 2 +- .../madara/webtoontr/src/WebtoonTR.kt | 2 +- .../madara/winterscan/src/WinterScan.kt | 2 +- .../wonderlandscan/src/WonderlandScan.kt | 2 +- .../madara/yanpfansub/src/YANPFansub.kt | 2 +- .../madara/yaoicomics/src/YaoiComics.kt | 2 +- .../madara/yaoitoshokan/src/YaoiToshokan.kt | 2 +- .../src/YetiskinRuyaManga.kt | 2 +- .../madara/yokaijump/src/YokaiJump.kt | 2 +- .../madara/yugenmangas/src/YugenMangas.kt | 4 +- .../madara/yuriverso/src/YuriVerso.kt | 2 +- .../overrides/madara/zeroscan/src/ZeroScan.kt | 2 +- .../madara/zinmanhwa/src/Zinmanhwa.kt | 2 +- .../madtheme/mangapuma/src/MangaPuma.kt | 2 +- .../mangakakalots/src/Mangakakalots.kt | 4 +- .../mangabz/mangabz/src/CookieInterceptor.kt | 2 +- .../overrides/mangabz/mangabz/src/Filters.kt | 10 +- .../ReadAttackOnTitanShingekiNoKyojinManga.kt | 2 +- ...adBokuNoHeroAcademiaMyHeroAcademiaManga.kt | 2 +- .../src/ReadKaguyaSamaMangaOnline.kt | 2 +- .../ReadTokyoGhoulReTokyoGhoulMangaOnline.kt | 2 +- .../arcrelight/src/ArcRelight.kt | 2 +- .../manga9co/src/MangaRawConstants.kt | 4 +- .../mangaraw/mangarawru/src/MangaRawRU.kt | 1 - .../mangasar/mangasup/src/MangasUp.kt | 2 +- .../mangasar/seemangas/src/Seemangas.kt | 2 +- .../arcanescan/src/Arcanescan.kt | 2 +- .../asurascans/src/AsuraScans.kt | 6 +- .../asurascans/src/AsuraScansFactory.kt | 2 +- .../constellarscans/src/ConstellarScans.kt | 2 +- .../diskusscan/src/DiskusScan.kt | 2 +- .../flamescans/src/FlameScans.kt | 6 +- .../flamescans/src/FlameScansFactory.kt | 2 +- .../franxxmangas/src/FranxxMangas.kt | 2 +- .../mangathemesia/iimanga/src/ARESManga.kt | 2 +- .../imaginescan/src/ImagineScan.kt | 2 +- .../inarimanga/src/InariManga.kt | 2 +- .../mangathemesia/komikav/src/KomikAV.kt | 2 +- .../mangathemesia/komikcast/src/KomikCast.kt | 16 +- .../komiklab/src/KomikLabFactory.kt | 2 +- .../mangathemesia/komikmama/src/KomikMama.kt | 6 +- .../mangathemesia/mangacim/src/Mangacim.kt | 2 +- .../mangaschan/src/MangasChan.kt | 2 +- .../mangathemesia/mangaswat/src/MangaSwat.kt | 2 +- .../mangathemesia/mangkomik/src/MangKomik.kt | 2 +- .../manhwaindo/src/ManhwaIndo.kt | 7 +- .../miauscan/src/MiauScanFactory.kt | 8 +- .../mangathemesia/mihentai/src/Mihentai.kt | 12 +- .../modescanlator/src/ModeScanlator.kt | 2 +- .../mundomangakun/src/MundoMangaKun.kt | 2 +- .../origamiorpheans/src/OrigamiOrpheans.kt | 2 +- .../mangathemesia/ozulscans/src/OzulScans.kt | 2 +- .../phoenixfansub/src/PhoenixFansub.kt | 2 +- .../mangathemesia/sheamanga/src/SheaManga.kt | 2 +- .../silencescan/src/SilenceScan.kt | 2 +- .../summerfansub/src/SummerFansub.kt | 2 +- .../src/TsundokuTraducoes.kt | 2 +- .../mangathemesia/turktoon/src/TurkToon.kt | 6 +- .../src/WorldRomanceTranslation.kt | 2 +- .../res/mipmap-hdpi/ic_launcher.png | Bin .../res/mipmap-mdpi/ic_launcher.png | Bin .../res/mipmap-xhdpi/ic_launcher.png | Bin .../res/mipmap-xxhdpi/ic_launcher.png | Bin .../res/mipmap-xxxhdpi/ic_launcher.png | Bin .../res/web_hi_res_512.png | Bin .../src/Haoman6glens.kt} | 4 +- .../mmrcms/animaregia/src/AnimaRegia.kt | 6 +- .../mmrcms/gekkouhentai/src/GekkouHentai.kt | 2 +- .../mmrcms/gekkouscan/src/GekkouScans.kt | 2 +- .../multichan/henchan/src/HenChan.kt | 33 ++-- .../multichan/mangachan/src/MangaChan.kt | 7 +- .../multichan/yaoichan/src/YaoiChan.kt | 7 +- .../overrides/sinmh/gufengmh/src/Gufengmh.kt | 3 +- .../sinmh/wuqimanga/src/WuqiManga.kt | 3 +- .../dongmanmanhua/src/DongmanManhua.kt | 7 +- .../webtoons/webtoons/src/WebtoonsFactory.kt | 4 +- .../webtoons/webtoons/src/WebtoonsSrc.kt | 8 +- .../wpcomics/nettruyen/src/NetTruyen.kt | 2 +- .../wpcomics/truyenchon/src/TruyenChon.kt | 2 +- .../overrides/zmanga/komikita/src/Komikita.kt | 6 +- .../tachiyomi/multisrc/a3manga/A3Manga.kt | 2 +- .../multisrc/a3manga/A3MangaUrlActivity.kt | 2 +- .../tachiyomi/multisrc/bakamanga/BakaManga.kt | 4 +- .../multisrc/bakkin/BakkinGenerator.kt | 2 +- .../tachiyomi/multisrc/bakkin/BakkinJSON.kt | 8 +- .../multisrc/bakkin/BakkinReaderX.kt | 2 +- .../tachiyomi/multisrc/bilibili/Bilibili.kt | 17 +- .../multisrc/bilibili/BilibiliDto.kt | 26 +-- .../multisrc/bilibili/BilibiliGenerator.kt | 6 +- .../tachiyomi/multisrc/comicake/ComiCake.kt | 8 +- .../multisrc/comicake/ComiCakeGenerator.kt | 2 +- .../tachiyomi/multisrc/eromuse/EroMuse.kt | 23 ++- .../multisrc/eromuse/EroMuseGenerator.kt | 2 +- .../tachiyomi/multisrc/fmreader/FMReader.kt | 25 +-- .../tachiyomi/multisrc/foolslide/FoolSlide.kt | 16 +- .../tachiyomi/multisrc/gattsu/Gattsu.kt | 9 +- .../multisrc/gattsu/GattsuGenerator.kt | 2 +- .../tachiyomi/multisrc/genkan/Genkan.kt | 3 +- .../multisrc/genkan/GenkanOriginal.kt | 2 +- .../multisrc/gigaviewer/GigaViewer.kt | 9 +- .../multisrc/gigaviewer/GigaViewerDto.kt | 8 +- .../gigaviewer/GigaViewerGenerator.kt | 2 +- .../tachiyomi/multisrc/grouple/GroupLe.kt | 18 +- .../multisrc/grouple/GroupLeGenerator.kt | 2 +- .../eu/kanade/tachiyomi/multisrc/guya/Guya.kt | 27 +-- .../tachiyomi/multisrc/heancms/HeanCms.kt | 16 +- .../tachiyomi/multisrc/heancms/HeanCmsDto.kt | 16 +- .../multisrc/heancms/HeanCmsFilters.kt | 2 +- .../multisrc/hentaihand/HentaiHand.kt | 38 +++-- .../multisrc/kemono/KemonoGenerator.kt | 2 +- .../multisrc/libgroup/LibGenerator.kt | 2 +- .../tachiyomi/multisrc/libgroup/LibGroup.kt | 73 +++++--- .../tachiyomi/multisrc/madara/Madara.kt | 84 ++++++--- .../multisrc/madara/MadaraUrlActivity.kt | 1 - .../tachiyomi/multisrc/madtheme/MadTheme.kt | 8 +- .../tachiyomi/multisrc/mangabox/MangaBox.kt | 17 +- .../multisrc/mangabz/MangabzTheme.kt | 2 +- .../multisrc/mangacatalog/MangaCatalog.kt | 4 +- .../multisrc/mangadventure/MangAdventure.kt | 24 ++- .../mangadventure/MangAdventureAPI.kt | 10 +- .../mangadventure/MangAdventureFilters.kt | 11 +- .../tachiyomi/multisrc/mangahub/MangaHub.kt | 15 +- .../multisrc/mangamainac/MangaMainac.kt | 9 +- .../mangamainac/MangaMainacGenerator.kt | 2 +- .../multisrc/mangaraw/ImageListParser.kt | 2 +- .../multisrc/mangaraw/MangaRawTheme.kt | 2 +- .../tachiyomi/multisrc/mangasar/MangaSar.kt | 2 +- .../multisrc/mangasar/MangaSarDto.kt | 14 +- .../multisrc/mangasar/MangaSarGenerator.kt | 2 +- .../multisrc/mangathemesia/MangaThemesia.kt | 37 ++-- .../mangathemesia/MangaThemesiaUrlActivity.kt | 1 - .../multisrc/mangaworld/MangaWorld.kt | 32 ++-- .../kanade/tachiyomi/multisrc/mccms/MCCMS.kt | 2 +- .../multisrc/mccms/MCCMSGenerator.kt | 93 +++++++--- .../eu/kanade/tachiyomi/multisrc/mdb/MDB.kt | 18 +- .../tachiyomi/multisrc/mmrcms/MMRCMS.kt | 40 +++-- .../multisrc/mmrcms/MMRCMSGenerator.kt | 2 +- .../multisrc/mmrcms/MMRCMSJsonGen.kt | 2 +- .../multisrc/monochrome/MonochromeAPI.kt | 6 +- .../multisrc/monochrome/MonochromeCMS.kt | 7 +- .../monochrome/MonochromeGenerator.kt | 2 +- .../multisrc/multichan/ChanGenerator.kt | 2 +- .../tachiyomi/multisrc/multichan/MultiChan.kt | 2 +- .../multisrc/mymangacms/MyMangaCMS.kt | 22 +-- .../mymangacms/MyMangaCMSGenerator.kt | 4 +- .../mymangacms/MyMangaCMSUrlActivity.kt | 2 +- .../tachiyomi/multisrc/nepnep/NepNep.kt | 50 +++--- .../multisrc/otakusanctuary/OtakuSanctuary.kt | 16 +- .../otakusanctuary/OtakuSanctuaryGenerator.kt | 4 +- .../tachiyomi/multisrc/paprika/Paprika.kt | 8 +- .../tachiyomi/multisrc/paprika/PaprikaAlt.kt | 2 +- .../multisrc/paprika/PaprikaAltGenerator.kt | 2 +- .../multisrc/pizzareader/PizzaReader.kt | 2 +- .../multisrc/pizzareader/PizzaReaderDto.kt | 14 +- .../pizzareader/PizzaReaderGenerator.kt | 2 +- .../multisrc/readerfront/ReaderFront.kt | 2 +- .../multisrc/readerfront/ReaderFrontAPI.kt | 6 +- .../kanade/tachiyomi/multisrc/sinmh/SinMH.kt | 4 +- .../multisrc/sinmh/SinMHGenerator.kt | 41 +++-- .../tachiyomi/multisrc/webtoons/Webtoons.kt | 17 +- .../multisrc/webtoons/WebtoonsGenerator.kt | 2 +- .../multisrc/webtoons/WebtoonsTranslate.kt | 2 +- .../multisrc/weebreader/Weebreader.kt | 6 +- .../tachiyomi/multisrc/wpcomics/WPComics.kt | 6 +- .../kanade/tachiyomi/multisrc/zbulu/Zbulu.kt | 8 +- .../multisrc/zeistmanga/ZeistManga.kt | 2 +- .../multisrc/zeistmanga/ZeistMangaDto.kt | 12 +- .../tachiyomi/multisrc/zmanga/ZManga.kt | 16 +- .../IntelijConfigurationGeneratorMain.kt | 3 +- .../java/generator/ThemeSourceGenerator.kt | 15 +- .../tachiyomi/extension/all/batoto/BatoTo.kt | 15 +- .../extension/all/batoto/BatoToFactory.kt | 4 +- .../extension/all/buondua/BuonDua.kt | 2 +- .../extension/all/comickfun/ComickFun.kt | 43 ++--- .../extension/all/comickfun/ComickFunDto.kt | 16 +- .../all/comickfun/ComickFunFactory.kt | 2 +- .../all/comickfun/ComickFunFilters.kt | 4 +- .../tachiyomi/extension/all/comico/Comico.kt | 38 +++-- .../extension/all/comico/ComicoFactory.kt | 2 +- .../extension/all/comico/ComicoModels.kt | 4 +- .../extension/all/commitstrip/CommitStrip.kt | 4 +- .../tachiyomi/extension/all/cubari/Cubari.kt | 4 +- .../extension/all/cubari/CubariFactory.kt | 2 +- .../all/cubari/RemoteStorageUtils.kt | 2 +- .../AndroidManifest.xml | 0 .../build.gradle | 2 +- .../res/mipmap-hdpi/ic_launcher.png | Bin .../res/mipmap-mdpi/ic_launcher.png | Bin .../res/mipmap-xhdpi/ic_launcher.png | Bin .../res/mipmap-xxhdpi/ic_launcher.png | Bin .../res/mipmap-xxxhdpi/ic_launcher.png | Bin .../res/web_hi_res_512.png | Bin .../all/dragonballmultiverse}/DbMFactory.kt | 4 +- .../all/dragonballmultiverse}/DbMultiverse.kt | 9 +- .../extension/all/ehentai/EHFactory.kt | 2 +- .../tachiyomi/extension/all/ehentai/EHUtil.kt | 5 +- .../extension/all/ehentai/EHentai.kt | 34 ++-- .../all/ehentai/ExGalleryMetadata.kt | 5 +- .../extension/all/ehentai/MetadataCopier.kt | 6 +- .../extension/all/everiaclub/EveriaClub.kt | 4 +- .../extension/all/hennojin/Hennojin.kt | 10 +- .../extension/all/hennojin/HennojinFactory.kt | 2 +- .../extension/all/imhentai/IMHentai.kt | 19 +-- .../extension/all/imhentai/IMHentaiFactory.kt | 2 +- .../extension/all/izneo/ImageInterceptor.kt | 4 +- .../tachiyomi/extension/all/izneo/IzneoAPI.kt | 6 +- .../extension/all/junmeitu/Junmeitu.kt | 2 +- .../tachiyomi/extension/all/kavita/Kavita.kt | 161 +++++++++--------- .../extension/all/kavita/KavitaConstants.kt | 6 +- .../extension/all/kavita/KavitaFactory.kt | 2 +- .../extension/all/kavita/dto/MangaDto.kt | 21 ++- .../extension/all/kavita/dto/MetadataDto.kt | 19 ++- .../extension/all/kavita/dto/Responses.kt | 7 +- .../tachiyomi/extension/all/komga/Komga.kt | 50 +++--- .../extension/all/komga/KomgaFactory.kt | 2 +- .../tachiyomi/extension/all/komga/dto/Dto.kt | 22 +-- .../extension/all/komga/dto/PageWrapperDto.kt | 2 +- .../extension/all/lanraragi/LANmodels.kt | 8 +- .../extension/all/lanraragi/LANraragi.kt | 10 +- .../all/lanraragi/LANraragiFactory.kt | 2 +- .../all/leagueoflegends/LOLModels.kt | 12 +- .../all/leagueoflegends/LOLUniverse.kt | 4 +- .../extension/all/luscious/Luscious.kt | 60 ++++--- .../extension/all/mangadex/MDConstants.kt | 2 +- .../extension/all/mangadex/MangaDex.kt | 34 ++-- .../extension/all/mangadex/MangaDexFactory.kt | 2 +- .../extension/all/mangadex/MangaDexFilters.kt | 22 +-- .../extension/all/mangadex/MangaDexHelper.kt | 48 +++--- .../extension/all/mangadex/MangaDexIntl.kt | 10 +- .../all/mangadex/MdAtHomeReportInterceptor.kt | 24 +-- .../all/mangadex/dto/AggregateDto.kt | 6 +- .../extension/all/mangadex/dto/CoverArtDto.kt | 2 +- .../extension/all/mangadex/dto/MangaDto.kt | 52 ++++-- .../extension/all/mangadex/dto/ResponseDto.kt | 4 +- .../extension/all/mangapark/MangaPark.kt | 14 +- .../all/mangapark/MangaParkFactory.kt | 2 +- .../all/mangapark/MangaParkFilters.kt | 16 +- .../extension/all/mangaplus/MangaPlus.kt | 2 +- .../extension/all/mangaplus/MangaPlusDto.kt | 28 +-- .../all/mangaplus/MangaPlusFactory.kt | 2 +- .../mangapluscreators/MangaPlusCreatorsDto.kt | 10 +- .../MangaPlusCreatorsFactory.kt | 2 +- .../all/mangareaderto/MangaReader.kt | 4 +- .../all/mangareaderto/MangaReaderFilters.kt | 42 ++--- .../extension/all/mangatoon/MangaToon.kt | 13 +- .../all/mangatoon/MangaToonFactory.kt | 2 +- .../extension/all/mangaup/MangaUpDto.kt | 14 +- .../tachiyomi/extension/all/mango/Mango.kt | 8 +- .../extension/all/meituatop/MeituaTop.kt | 5 +- .../all/myreadingmanga/MyReadingManga.kt | 13 +- .../myreadingmanga/MyReadingMangaFactory.kt | 2 +- .../extension/all/netcomics/GenreFilter.kt | 2 +- .../extension/all/netcomics/Netcomics.kt | 8 +- .../extension/all/netcomics/NetcomicsAPI.kt | 4 +- .../extension/all/nhentai/NHFactory.kt | 2 +- .../extension/all/nhentai/NHentai.kt | 13 +- .../extension/all/ninemanga/NineManga.kt | 14 +- .../all/ninemanga/NineMangaFactory.kt | 14 +- .../extension/all/noisemanga/NoiseManga.kt | 2 +- .../all/noisemanga/NoiseMangaFactory.kt | 2 +- .../extension/all/peppercarrot/Filters.kt | 12 +- .../all/peppercarrot/PepperCarrot.kt | 2 +- .../extension/all/peppercarrot/Preferences.kt | 2 +- .../extension/all/photos18/Photos18.kt | 11 +- .../all/sandraandwoo/SandraAndWoo.kt | 10 +- .../all/simplyhentai/SimplyHentai.kt | 4 +- .../all/simplyhentai/SimplyHentaiAPI.kt | 6 +- .../tachiyomi/extension/all/tachidesk/Dto.kt | 2 +- .../extension/all/tachidesk/Tachidesk.kt | 8 +- .../extension/all/tappytoon/Tappytoon.kt | 7 +- .../extension/all/tappytoon/TappytoonAPI.kt | 4 +- .../thelibraryofohara/TheLibraryOfOhara.kt | 6 +- .../TheLibraryOfOharaFactory.kt | 2 +- .../extension/all/toomics/ToomicsFactory.kt | 2 +- .../extension/all/toomics/ToomicsGlobal.kt | 5 +- .../all/vinnieVeritas/vinnieVeritasFactory.kt | 2 +- .../extension/all/xinmeitulu/Xinmeitulu.kt | 4 +- .../tachiyomi/extension/all/xkcd/Xkcd.kt | 2 +- .../all/yaoimangaonline/YaoiMangaFilters.kt | 4 +- .../all/yaoimangaonline/YaoiMangaOnline.kt | 2 +- .../extension/ar/asgardteam/AsgardTeam.kt | 2 +- .../tachiyomi/extension/ar/gmanga/Gmanga.kt | 22 +-- .../extension/ar/gmanga/GmangaFilters.kt | 40 ++--- .../extension/ar/gmanga/GmangaPreferences.kt | 15 +- .../tachiyomi/extension/ar/mangaae/MangaAe.kt | 6 +- .../tachiyomi/extension/ar/remanga/REManga.kt | 10 +- .../tachiyomi/extension/ar/teamx/TeamX.kt | 11 +- .../tachiyomi/extension/en/aurora/Aurora.kt | 13 +- .../extension/en/brewingscans/BrewingScans.kt | 2 +- .../en/brewingscans/BrewingSeries.kt | 2 +- .../extension/en/buttsmithy/Buttsmithy.kt | 28 +-- .../extension/en/clonemanga/CloneManga.kt | 6 +- .../extension/en/comicastle/Comicastle.kt | 2 +- .../extension/en/comicextra/ComicExtra.kt | 5 +- .../en/darklegacycomics/DarkLegacyComics.kt | 4 +- .../digitalcomicmuseum/DigitalComicMuseum.kt | 2 +- .../tachiyomi/extension/en/doujins/Doujins.kt | 24 +-- .../extension/en/dynasty/DynastyDoujins.kt | 14 +- .../extension/en/dynasty/DynastyFactory.kt | 2 +- .../extension/en/dynasty/DynastyScans.kt | 2 +- .../extension/en/earlymanga/EarlyManga.kt | 4 +- .../en/eggporncomics/Eggporncomics.kt | 8 +- .../extension/en/elanschool/ElanSchool.kt | 6 +- .../extension/en/grrlpower/GrrlPower.kt | 14 +- .../tachiyomi/extension/en/hbrowse/HBrowse.kt | 4 +- .../extension/en/hentai2read/Hentai2Read.kt | 26 +-- .../extension/en/hentaifox/HentaiFox.kt | 8 +- .../extension/en/hentaihere/HentaiHere.kt | 4 +- .../extension/en/hiveworks/Hiveworks.kt | 29 ++-- .../extension/en/hwtmanga/HWTFilters.kt | 10 +- .../extension/en/hwtmanga/HWTManga.kt | 12 +- .../extension/en/hwtmanga/HWTModels.kt | 8 +- .../extension/en/keenspot/TwoKinds.kt | 13 +- .../KillSixBillionDemons.kt | 20 ++- .../extension/en/kouhaiwork/KouhaiAPI.kt | 16 +- .../extension/en/kouhaiwork/KouhaiWork.kt | 8 +- .../extension/en/latisbooks/Latisbooks.kt | 2 +- .../extension/en/lemonfont/LemonFont.kt | 2 +- .../en/loadingartist/LoadingArtist.kt | 8 +- .../extension/en/mangadoom/MangaDoom.kt | 45 +++-- .../extension/en/mangafox/MangaFox.kt | 62 +++---- .../extension/en/mangafreak/Mangafreak.kt | 12 +- .../tachiyomi/extension/en/mangago/Mangago.kt | 14 +- .../extension/en/mangahasu/Mangahasu.kt | 14 +- .../extension/en/mangahere/Mangahere.kt | 21 +-- .../extension/en/mangajar/MangaJar.kt | 21 ++- .../extension/en/mangakatana/MangaKatana.kt | 18 +- .../extension/en/mangamiso/MangaMiso.kt | 34 ++-- .../en/mangamiso/MangaMisoObjects.kt | 16 +- .../extension/en/mangapark/MangaPark.kt | 44 ++--- .../extension/en/mangapill/MangaPill.kt | 14 +- .../extension/en/mangaplex/MangaPlex.kt | 13 +- .../extension/en/mangarawclub/MangaRawClub.kt | 35 ++-- .../extension/en/mangasail/Mangasail.kt | 8 +- .../tachiyomi/extension/en/manta/MantaAPI.kt | 14 +- .../extension/en/manta/MantaComics.kt | 2 +- .../extension/en/manta/MantaFilters.kt | 4 +- .../extension/en/megatokyo/Megatokyo.kt | 17 +- .../extension/en/multporn/Multporn.kt | 42 ++--- .../en/myhentaicomics/MyHentaiComics.kt | 10 +- .../en/myhentaigallery/MyHentaiGallery.kt | 8 +- .../tachiyomi/extension/en/nana/Nana.kt | 4 +- .../extension/en/nineanime/NineAnime.kt | 6 +- .../extension/en/ninehentai/NineHentai.kt | 29 ++-- .../extension/en/ninehentai/NineHentaiDto.kt | 16 +- .../tachiyomi/extension/en/oglaf/Oglaf.kt | 2 +- .../tachiyomi/extension/en/oots/oots.kt | 3 +- .../extension/en/patchfriday/PatchFriday.kt | 2 +- .../extension/en/purplecress/PurpleCress.kt | 4 +- .../tachiyomi/extension/en/pururin/Pururin.kt | 10 +- .../extension/en/pururin/PururinAPI.kt | 8 +- .../extension/en/pururin/PururinFilters.kt | 14 +- .../tachiyomi/extension/en/pururin/Search.kt | 5 +- .../extension/en/rainofsnow/RainOfSnow.kt | 2 +- .../extension/en/randowiz/Randowiz.kt | 12 +- .../en/readcomiconline/Readcomiconline.kt | 4 +- .../en/readmangatoday/Readmangatoday.kt | 4 +- .../en/reallifecomics/RealLifeComics.kt | 2 +- .../extension/en/reaperscans/ReaperScans.kt | 3 +- .../en/reaperscans/ReaperScansDto.kt | 6 +- .../en/silentmangaaudition/ExtensionData.kt | 48 +++--- .../en/soushiyofamiliar/SoushiyoFamiliar.kt | 2 +- .../extension/en/tapastic/Tapastic.kt | 46 ++--- .../extension/en/tcbscans/TCBScans.kt | 4 +- .../en/theduckwebcomics/TheDuckFilters.kt | 14 +- .../en/theduckwebcomics/TheDuckWebcomics.kt | 2 +- .../en/thepropertyofhate/ThePropertyOfHate.kt | 2 +- .../tachiyomi/extension/en/tsumino/Tsumino.kt | 15 +- .../extension/en/tsumino/TsuminoUtils.kt | 12 +- .../extension/en/vgperson/Vgperson.kt | 11 +- .../en/vizshonenjump/VizImageInterceptor.kt | 15 +- .../en/vizshonenjump/VizShonenJump.kt | 2 +- .../en/vizshonenjump/VizShonenJumpDto.kt | 6 +- .../extension/en/voyceme/VoyceMeDto.kt | 12 +- .../extension/en/warforrayuba/WarForRayuba.kt | 6 +- .../en/warforrayuba/dto/ChapterDto.kt | 2 +- .../extension/en/warforrayuba/dto/PageDto.kt | 2 +- .../extension/en/warforrayuba/dto/RoundDto.kt | 2 +- .../extension/en/webcomics/Webcomics.kt | 6 +- .../extension/en/webnovel/Webnovel.kt | 18 +- .../extension/en/webnovel/WebnovelDto.kt | 6 +- .../extension/en/webnovel/WebnovelFilter.kt | 6 +- .../extension/en/zeroscans/ZeroScans.kt | 33 ++-- .../extension/en/zeroscans/ZeroScansDto.kt | 28 +-- .../extension/en/zeroscans/ZeroScansHelper.kt | 6 +- .../extension/en/zinchanmanga/ZinChanAPI.kt | 12 +- .../extension/en/zinchanmanga/ZinChanCert.kt | 2 +- .../extension/en/zinchanmanga/ZinChanManga.kt | 2 +- .../extension/es/heavenmanga/HeavenManga.kt | 21 ++- .../extension/es/ikuhentai/Ikuhentai.kt | 13 +- .../tachiyomi/extension/es/inmanga/InManga.kt | 14 +- .../extension/es/inmanga/InMangaResultDto.kt | 4 +- .../tachiyomi/extension/es/kumanga/Kumanga.kt | 12 +- .../extension/es/lectormanga/LectorManga.kt | 67 +++++--- .../es/leermangasxyz/LeerMangasXYZ.kt | 5 +- .../es/manhwalatino/ManhwaLatinoSiteParser.kt | 26 +-- .../es/manhwalatino/filters/GenreTagFilter.kt | 4 +- .../es/manhwalatino/filters/UriPartFilter.kt | 3 +- .../extension/es/mangamx/MangaOni.kt | 28 +-- .../extension/es/manhwasnet/ManhwasNet.kt | 2 +- .../extension/es/tmohentai/TMOHentai.kt | 22 +-- .../es/tumangaonline/TuMangaOnline.kt | 57 ++++--- .../tachiyomi/extension/es/vcpvmp/VCPVMP.kt | 14 +- .../extension/es/vcpvmp/VCPVMPFactory.kt | 10 +- .../extension/fr/animesama/AnimeSama.kt | 2 +- .../extension/fr/aralosbd/AralosBD.kt | 6 +- .../extension/fr/furyosquad/FuryoSquad.kt | 4 +- .../extension/fr/japanread/Japanread.kt | 20 ++- .../tachiyomi/extension/fr/japscan/Japscan.kt | 14 +- .../extension/fr/mangakawaii/MangaKawaii.kt | 8 +- .../extension/fr/scanmanga/ScanManga.kt | 3 +- .../extension/id/bacakomik/BacaKomik.kt | 16 +- .../tachiyomi/extension/id/comicfx/ComicFx.kt | 21 ++- .../extension/id/doujindesu/DoujinDesu.kt | 10 +- .../extension/id/komikindoid/KomikIndoID.kt | 20 +-- .../tachiyomi/extension/id/komiku/Komiku.kt | 10 +- .../tachiyomi/extension/id/mangaku/Mangaku.kt | 9 +- .../extension/it/animegdrclub/AnimeGDRClub.kt | 6 +- .../it/demoneceleste/DemoneCeleste.kt | 11 +- .../it/hentaifantasy/HentaiFantasy.kt | 4 +- .../it/shingekinoshoujo/ShingekiNoShoujo.kt | 12 +- .../extension/it/zeurelscan/ZeurelScan.kt | 2 +- .../extension/ja/comicnewtype/ComicNewtype.kt | 3 +- .../tachiyomi/extension/ja/ganma/GanmaDto.kt | 5 +- .../extension/ja/mangacross/MangaCross.kt | 22 ++- .../extension/ja/mangacross/MangaCrossDto.kt | 4 +- .../ja/nicovideoseiga/NicovideoSeiga.kt | 17 +- .../extension/ja/rawdevart/Rawdevart.kt | 39 +++-- .../extension/ja/senmanga/SenManga.kt | 14 +- .../tachiyomi/extension/ja/twi4/Twi4.kt | 32 ++-- .../tachiyomi/extension/ko/jmana/JMana.kt | 2 +- .../ko/navercomic/NaverComicFactory.kt | 2 +- .../extension/ko/newtoki/ManaToki.kt | 18 +- .../tachiyomi/extension/ko/newtoki/NewToki.kt | 4 +- .../extension/ko/newtoki/NewTokiWebtoon.kt | 17 +- .../tachiyomi/extension/ko/toonkor/Toonkor.kt | 6 +- .../extension/pt/argosscan/ArgosScanDto.kt | 10 +- .../extension/pt/bruttal/BruttalDto.kt | 10 +- .../tachiyomi/extension/pt/hqnow/HQNow.kt | 8 +- .../tachiyomi/extension/pt/hqnow/HQNowDto.kt | 6 +- .../extension/pt/mangavibe/MangaVibe.kt | 7 +- .../extension/pt/mangavibe/MangaVibeDto.kt | 8 +- .../extension/pt/muitomanga/MuitoMangaDto.kt | 4 +- .../extension/pt/mundohentai/MundoHentai.kt | 4 +- .../tachiyomi/extension/pt/opex/OnePieceEx.kt | 2 +- .../extension/pt/saikaiscan/SaikaiScan.kt | 10 +- .../extension/pt/saikaiscan/SaikaiScanDto.kt | 14 +- .../pt/saikaiscan/SaikaiScanFilters.kt | 2 +- .../tachiyomi/extension/pt/taosect/TaoSect.kt | 10 +- .../extension/pt/taosect/TaoSectDto.kt | 12 +- .../extension/pt/taosect/TaoSectFilters.kt | 7 +- .../tachiyomi/extension/ru/acomics/AComics.kt | 8 +- .../tachiyomi/extension/ru/comx/ComX.kt | 56 +++--- .../tachiyomi/extension/ru/desu/Desu.kt | 8 +- .../extension/ru/mangabook/MangaBook.kt | 15 +- .../extension/ru/mangaclub/MangaClub.kt | 10 +- .../extension/ru/mangapoisk/MangaPoisk.kt | 12 +- .../tachiyomi/extension/ru/newbie/Newbie.kt | 21 ++- .../tachiyomi/extension/ru/newbie/dto/Dto.kt | 18 +- .../extension/ru/nudemoon/Nudemoon.kt | 12 +- .../tachiyomi/extension/ru/remanga/Remanga.kt | 42 +++-- .../tachiyomi/extension/ru/remanga/dto/Dto.kt | 31 ++-- .../extension/ru/unicomics/UniComics.kt | 33 ++-- .../extension/ru/webofcomics/WebOfComics.kt | 52 +++--- .../extension/ru/mangabook/YagamiProject.kt | 17 +- .../extension/th/mikudoujin/MikuDoujin.kt | 9 +- .../extension/th/nekopost/Nekopost.kt | 8 +- .../th/nekopost/model/RawChapterInfo.kt | 2 +- .../th/nekopost/model/RawPageItem.kt | 2 +- .../th/nekopost/model/RawProjectCategory.kt | 2 +- .../th/nekopost/model/RawProjectInfo.kt | 2 +- .../nekopost/model/RawProjectNameListItem.kt | 2 +- .../th/nekopost/model/RawProjectSummary.kt | 2 +- .../nekopost/model/RawProjectSummaryList.kt | 2 +- .../extension/th/niceoppai/Niceoppai.kt | 12 +- .../extension/tr/mangadenizi/MangaDenizi.kt | 3 +- .../extension/uk/mangainua/Mangainua.kt | 6 +- .../extension/vi/blogtruyen/BlogTruyen.kt | 14 +- .../vi/blogtruyen/BlogTruyenUrlActivity.kt | 2 +- .../extension/vi/cuutruyen/CuuTruyen.kt | 4 +- .../vi/cuutruyen/CuuTruyenImageInterceptor.kt | 2 +- .../vi/cuutruyen/CuuTruyenUrlActivity.kt | 2 +- .../extension/vi/cuutruyen/dto/ResponseDto.kt | 2 +- .../extension/vi/hentaivn/HentaiVN.kt | 17 +- .../extension/vi/lxhentai/LxHentai.kt | 4 +- .../vi/lxhentai/LxHentaiUrlActivity.kt | 2 +- .../tachiyomi/extension/vi/MangaXY/MangaXY.kt | 28 +-- .../vi/medoctruyentranh/MeDocTruyenTranh.kt | 5 +- .../tachiyomi/extension/vi/qmanga/QManga.kt | 24 +-- .../extension/vi/qmanga/QMangaUrlActivity.kt | 2 +- .../extension/vi/truyengihot/TruyenGiHot.kt | 44 ++--- .../vi/truyengihot/TruyenGiHotUrlActivity.kt | 2 +- .../extension/vi/truyenqq/TruyenQQ.kt | 12 +- .../extension/vi/truyentranh8/TruyenTranh8.kt | 24 +-- .../truyentranh8/TruyenTranh8UrlActivity.kt | 2 +- .../extension/vi/yurineko/YuriNeko.kt | 12 +- .../vi/yurineko/YuriNekoUrlActivity.kt | 2 +- .../extension/vi/yurineko/dto/MangaDto.kt | 2 +- .../extension/zh/baimangu/Baimangu.kt | 4 +- .../extension/zh/baozimanhua/Baozi.kt | 14 +- .../extension/zh/baozimanhua/BaoziFilters.kt | 18 +- .../tachiyomi/extension/zh/dmzj/Filters.kt | 16 +- .../tachiyomi/extension/zh/iqiyi/Iqiyi.kt | 8 +- .../zh/jinmantiantang/Jinmantiantang.kt | 16 +- .../JinmantiantangPreferences.kt | 20 ++- .../zh/kuaikanmanhua/Kuaikanmanhua.kt | 15 +- .../tachiyomi/extension/zh/manhuagui/Comic.kt | 2 +- .../extension/zh/manhuagui/Manhuagui.kt | 64 +++---- .../tachiyomi/extension/zh/manhuagui/Sl.kt | 2 +- .../extension/zh/manhuaren/Manhuaren.kt | 22 +-- .../tachiyomi/extension/zh/manwa/Manwa.kt | 4 +- .../extension/zh/picacomic/PicaApiSchemas.kt | 4 +- .../extension/zh/picacomic/Picacomic.kt | 36 ++-- .../extension/zh/roumanwu/Roumanwu.kt | 2 +- .../extension/zh/roumanwu/RoumanwuDto.kt | 7 +- .../zh/tencentcomics/TencentComics.kt | 19 ++- .../zh/terrahistoricus/TerraHistoricusDto.kt | 7 +- .../tachiyomi/extension/zh/wnacg/wnacg.kt | 4 +- .../tachiyomi/extension/zh/yidan/Dto.kt | 2 +- .../tachiyomi/extension/zh/yidan/Filters.kt | 6 +- .../tachiyomi/extension/zh/zerobyw/Zerobyw.kt | 19 ++- 701 files changed, 3357 insertions(+), 2780 deletions(-) rename multisrc/overrides/mccms/{haoman6_glens => haoman6glens}/res/mipmap-hdpi/ic_launcher.png (100%) rename multisrc/overrides/mccms/{haoman6_glens => haoman6glens}/res/mipmap-mdpi/ic_launcher.png (100%) rename multisrc/overrides/mccms/{haoman6_glens => haoman6glens}/res/mipmap-xhdpi/ic_launcher.png (100%) rename multisrc/overrides/mccms/{haoman6_glens => haoman6glens}/res/mipmap-xxhdpi/ic_launcher.png (100%) rename multisrc/overrides/mccms/{haoman6_glens => haoman6glens}/res/mipmap-xxxhdpi/ic_launcher.png (100%) rename multisrc/overrides/mccms/{haoman6_glens => haoman6glens}/res/web_hi_res_512.png (100%) rename multisrc/overrides/mccms/{haoman6_glens/src/Haoman6_glens.kt => haoman6glens/src/Haoman6glens.kt} (67%) rename src/all/{dragonball_multiverse => dragonballmultiverse}/AndroidManifest.xml (100%) rename src/all/{dragonball_multiverse => dragonballmultiverse}/build.gradle (81%) rename src/all/{dragonball_multiverse => dragonballmultiverse}/res/mipmap-hdpi/ic_launcher.png (100%) rename src/all/{dragonball_multiverse => dragonballmultiverse}/res/mipmap-mdpi/ic_launcher.png (100%) rename src/all/{dragonball_multiverse => dragonballmultiverse}/res/mipmap-xhdpi/ic_launcher.png (100%) rename src/all/{dragonball_multiverse => dragonballmultiverse}/res/mipmap-xxhdpi/ic_launcher.png (100%) rename src/all/{dragonball_multiverse => dragonballmultiverse}/res/mipmap-xxxhdpi/ic_launcher.png (100%) rename src/all/{dragonball_multiverse => dragonballmultiverse}/res/web_hi_res_512.png (100%) rename src/all/{dragonball_multiverse/src/eu/kanade/tachiyomi/extension/all/dragonball_multiverse => dragonballmultiverse/src/eu/kanade/tachiyomi/extension/all/dragonballmultiverse}/DbMFactory.kt (97%) rename src/all/{dragonball_multiverse/src/eu/kanade/tachiyomi/extension/all/dragonball_multiverse => dragonballmultiverse/src/eu/kanade/tachiyomi/extension/all/dragonballmultiverse}/DbMultiverse.kt (94%) diff --git a/.editorconfig b/.editorconfig index e917e6912..79a830918 100644 --- a/.editorconfig +++ b/.editorconfig @@ -8,5 +8,7 @@ indent_size = 4 indent_style = space insert_final_newline = true trim_trailing_whitespace = true +ij_kotlin_allow_trailing_comma = true +ij_kotlin_allow_trailing_comma_on_call_site = true ij_kotlin_name_count_to_use_star_import = 2147483647 ij_kotlin_name_count_to_use_star_import_for_members = 2147483647 diff --git a/common.gradle b/common.gradle index b4b4e061d..07a73d20c 100644 --- a/common.gradle +++ b/common.gradle @@ -80,6 +80,14 @@ android { jvmTarget = JavaVersion.VERSION_1_8.toString() freeCompilerArgs += "-Xopt-in=kotlinx.serialization.ExperimentalSerializationApi" } + + kotlinter { + experimentalRules = true + disabledRules = [ + "experimental:argument-list-wrapping", // Doesn't play well with Android Studio + "experimental:comment-wrapping", + ] + } } repositories { diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 533b28469..e80a3e9d9 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -7,7 +7,7 @@ serialization_version = "1.4.0" gradle-agp = { module = "com.android.tools.build:gradle", version = "7.4.1" } gradle-kotlin = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", version.ref = "kotlin_version" } gradle-serialization = { module = "org.jetbrains.kotlin:kotlin-serialization", version.ref = "kotlin_version" } -gradle-kotlinter = { module = "org.jmailen.gradle:kotlinter-gradle", version = "3.6.0" } +gradle-kotlinter = { module = "org.jmailen.gradle:kotlinter-gradle", version = "3.13.0" } tachiyomi-lib = { module = "com.github.tachiyomiorg:extensions-lib", version = "1.4.0" } diff --git a/multisrc/overrides/bakamanga/manhuamanganet/src/ManhuaMangaNet.kt b/multisrc/overrides/bakamanga/manhuamanganet/src/ManhuaMangaNet.kt index 3d484c802..6b15ad6b3 100644 --- a/multisrc/overrides/bakamanga/manhuamanganet/src/ManhuaMangaNet.kt +++ b/multisrc/overrides/bakamanga/manhuamanganet/src/ManhuaMangaNet.kt @@ -5,7 +5,7 @@ import eu.kanade.tachiyomi.multisrc.bakamanga.BakaManga class ManhuaMangaNet : BakaManga( "ManhuaManga.net", "https://manhuamanga.net", - "en" + "en", ) { override fun getGenreList() = arrayOf( Pair("All", ""), diff --git a/multisrc/overrides/bakamanga/manhwamanganet/src/ManhwaMangaNet.kt b/multisrc/overrides/bakamanga/manhwamanganet/src/ManhwaMangaNet.kt index 1ab29561b..90a5f357b 100644 --- a/multisrc/overrides/bakamanga/manhwamanganet/src/ManhwaMangaNet.kt +++ b/multisrc/overrides/bakamanga/manhwamanganet/src/ManhwaMangaNet.kt @@ -5,7 +5,7 @@ import eu.kanade.tachiyomi.multisrc.bakamanga.BakaManga class ManhwaMangaNet : BakaManga( "ManhwaManga.net", "https://manhwamanga.net", - "en" + "en", ) { override fun getGenreList() = arrayOf( Pair("All", ""), diff --git a/multisrc/overrides/bakamanga/manhwaxxl/src/ManhwaXXL.kt b/multisrc/overrides/bakamanga/manhwaxxl/src/ManhwaXXL.kt index 07c2070ef..ba65d8f4f 100644 --- a/multisrc/overrides/bakamanga/manhwaxxl/src/ManhwaXXL.kt +++ b/multisrc/overrides/bakamanga/manhwaxxl/src/ManhwaXXL.kt @@ -5,7 +5,7 @@ import eu.kanade.tachiyomi.multisrc.bakamanga.BakaManga class ManhwaXXL : BakaManga( "Manhwa XXL", "https://manhwaxxl.com", - "en" + "en", ) { override fun getGenreList() = arrayOf( Pair("All", ""), diff --git a/multisrc/overrides/bakamanga/mwmanhwa/src/MWManhwa.kt b/multisrc/overrides/bakamanga/mwmanhwa/src/MWManhwa.kt index 0ec30735e..7e68041cc 100644 --- a/multisrc/overrides/bakamanga/mwmanhwa/src/MWManhwa.kt +++ b/multisrc/overrides/bakamanga/mwmanhwa/src/MWManhwa.kt @@ -5,7 +5,7 @@ import eu.kanade.tachiyomi.multisrc.bakamanga.BakaManga class MWManhwa : BakaManga( "MWManhwa", "https://mwmanhwa.net", - "all" + "all", ) { override fun getGenreList() = arrayOf( Pair("All", ""), diff --git a/multisrc/overrides/bilibili/bilibilicomics/src/BilibiliComicsFactory.kt b/multisrc/overrides/bilibili/bilibilicomics/src/BilibiliComicsFactory.kt index f9e8c9cc6..8a6a6a3eb 100644 --- a/multisrc/overrides/bilibili/bilibilicomics/src/BilibiliComicsFactory.kt +++ b/multisrc/overrides/bilibili/bilibilicomics/src/BilibiliComicsFactory.kt @@ -46,7 +46,7 @@ class BilibiliComicsFactory : SourceFactory { abstract class BilibiliComics(lang: String) : Bilibili( "BILIBILI COMICS", "https://www.bilibilicomics.com", - lang + lang, ) { override val client: OkHttpClient = super.client.newBuilder() @@ -245,7 +245,7 @@ abstract class BilibiliComics(lang: String) : Bilibili( val refreshTokenRequest = refreshTokenRequest( accessTokenCookie!!.accessToken, - accessTokenCookie!!.refreshToken + accessTokenCookie!!.refreshToken, ) val refreshTokenResponse = chain.proceed(refreshTokenRequest) @@ -294,7 +294,7 @@ abstract class BilibiliComics(lang: String) : Bilibili( return BilibiliAccessTokenCookie( accessToken.accessToken, accessToken.refreshToken, - accessTokenCookie!!.area + accessTokenCookie!!.area, ) } @@ -334,7 +334,7 @@ class BilibiliComicsEn : BilibiliComics(BilibiliIntl.ENGLISH) { BilibiliTag("Romance", 13), BilibiliTag("Slice of Life", 21), BilibiliTag("Suspense", 41), - BilibiliTag("Teen", 20) + BilibiliTag("Teen", 20), ) } @@ -354,7 +354,7 @@ class BilibiliComicsCn : BilibiliComics(BilibiliIntl.SIMPLIFIED_CHINESE) { BilibiliTag("百合", 16), BilibiliTag("玄幻", 30), BilibiliTag("悬疑", 41), - BilibiliTag("科幻", 8) + BilibiliTag("科幻", 8), ) } @@ -371,7 +371,7 @@ class BilibiliComicsId : BilibiliComics(BilibiliIntl.INDONESIAN) { BilibiliTag("Komedi", 14), BilibiliTag("Menegangkan", 41), BilibiliTag("Remaja", 20), - BilibiliTag("Romantis", 13) + BilibiliTag("Romantis", 13), ) } @@ -396,7 +396,7 @@ class BilibiliComicsEs : BilibiliComics(BilibiliIntl.SPANISH) { BilibiliTag("Romance", 13), BilibiliTag("Suspenso", 41), BilibiliTag("Urbano", 9), - BilibiliTag("Wuxia", 103) + BilibiliTag("Wuxia", 103), ) } @@ -411,6 +411,6 @@ class BilibiliComicsFr : BilibiliComics(BilibiliIntl.FRENCH) { BilibiliTag("GL", 16), BilibiliTag("Fantasy Orientale", 30), BilibiliTag("Suspense", 41), - BilibiliTag("Moderne", 111) + BilibiliTag("Moderne", 111), ) } diff --git a/multisrc/overrides/bilibili/bilibilimanga/src/BilibiliManga.kt b/multisrc/overrides/bilibili/bilibilimanga/src/BilibiliManga.kt index 3f6779243..5530389a4 100644 --- a/multisrc/overrides/bilibili/bilibilimanga/src/BilibiliManga.kt +++ b/multisrc/overrides/bilibili/bilibilimanga/src/BilibiliManga.kt @@ -11,7 +11,7 @@ import okhttp3.Response class BilibiliManga : Bilibili( "哔哩哔哩漫画", "https://manga.bilibili.com", - BilibiliIntl.SIMPLIFIED_CHINESE + BilibiliIntl.SIMPLIFIED_CHINESE, ) { override val id: Long = 3561131545129718586 @@ -40,7 +40,7 @@ class BilibiliManga : Bilibili( BilibiliTag(intl.sortPopular, 0), BilibiliTag(intl.sortUpdated, 1), BilibiliTag(intl.sortFollowers, 2), - BilibiliTag(intl.sortAdded, 3) + BilibiliTag(intl.sortAdded, 3), ) override fun getAllPrices(): Array = diff --git a/multisrc/overrides/eromuse/erofus/src/Erofus.kt b/multisrc/overrides/eromuse/erofus/src/Erofus.kt index 7c94e2487..1bb7fb34e 100644 --- a/multisrc/overrides/eromuse/erofus/src/Erofus.kt +++ b/multisrc/overrides/eromuse/erofus/src/Erofus.kt @@ -153,13 +153,13 @@ class Erofus : EroMuse("Erofus", "https://www.erofus.com") { Triple("Magnifire Comics", "/comics/magnifire-comics", AUTHOR), Triple("Reptileye Comics", "/comics/reptileye-comics", AUTHOR), Triple("ProjectPinkXXX.com Comics", "/comics/projectpinkxxx_com-comics", AUTHOR), - Triple("CallMePlisskin Comics", "/comics/callmeplisskin-comics", AUTHOR) + Triple("CallMePlisskin Comics", "/comics/callmeplisskin-comics", AUTHOR), ) override fun getSortList() = arrayOf( Pair("Viewed", "viewed"), Pair("Liked", "liked"), Pair("Date", "recent"), - Pair("A-Z", "az") + Pair("A-Z", "az"), ) } diff --git a/multisrc/overrides/fmreader/mangatr/src/MangaTR.kt b/multisrc/overrides/fmreader/mangatr/src/MangaTR.kt index 224f2a95c..3d760538a 100644 --- a/multisrc/overrides/fmreader/mangatr/src/MangaTR.kt +++ b/multisrc/overrides/fmreader/mangatr/src/MangaTR.kt @@ -22,6 +22,7 @@ class MangaTR : FMReader("Manga-TR", "https://manga-tr.com", "tr") { add("User-Agent", "Mozilla/5.0 (Windows NT 6.3; WOW64)") } override fun popularMangaNextPageSelector() = "div.btn-group:not(div.btn-block) button.btn-info" + // TODO: genre search possible but a bit of a pain override fun getFilterList() = FilterList() diff --git a/multisrc/overrides/fmreader/manhwa18/src/Manhwa18.kt b/multisrc/overrides/fmreader/manhwa18/src/Manhwa18.kt index 132321e54..feb745b8d 100644 --- a/multisrc/overrides/fmreader/manhwa18/src/Manhwa18.kt +++ b/multisrc/overrides/fmreader/manhwa18/src/Manhwa18.kt @@ -77,7 +77,7 @@ class Manhwa18 : FMReader("Manhwa18", "https://manhwa18.com", "en") { name = element.attr("title") date_upload = SimpleDateFormat("dd/MM/yyyy", Locale.US).parse( - element.select(".chapter-time").text().substringAfter(" - ") + element.select(".chapter-time").text().substringAfter(" - "), )?.time ?: 0L chapter_number = element.attr("time").substringAfterLast(' ').toFloatOrNull() ?: -1f } diff --git a/multisrc/overrides/fmreader/rawlh/src/WeLoveManga.kt b/multisrc/overrides/fmreader/rawlh/src/WeLoveManga.kt index dcb80e01f..a6c8e05cb 100644 --- a/multisrc/overrides/fmreader/rawlh/src/WeLoveManga.kt +++ b/multisrc/overrides/fmreader/rawlh/src/WeLoveManga.kt @@ -28,6 +28,7 @@ class WeLoveManga : FMReader("WeLoveManga", "https://weloma.art", "ja") { Page(i, document.location(), img.decoded()) } } + // Referer needs to be chapter URL override fun imageRequest(page: Page): Request = GET(page.imageUrl!!, headersBuilder().set("Referer", page.url).build()) } diff --git a/multisrc/overrides/foolslide/lecercleduscan/src/LeCercleDuScan.kt b/multisrc/overrides/foolslide/lecercleduscan/src/LeCercleDuScan.kt index 77f42101b..fb22ae810 100644 --- a/multisrc/overrides/foolslide/lecercleduscan/src/LeCercleDuScan.kt +++ b/multisrc/overrides/foolslide/lecercleduscan/src/LeCercleDuScan.kt @@ -10,6 +10,6 @@ class LeCercleDuScan : FoolSlide("Le Cercle du Scan", "https://lel.lecercledusca "aujourd'hui" -> "today" "demain" -> "tomorrow" else -> lcDate - } + }, ) } diff --git a/multisrc/overrides/gattsu/hentaiseason/src/HentaiSeason.kt b/multisrc/overrides/gattsu/hentaiseason/src/HentaiSeason.kt index c15318229..eb601f2ac 100644 --- a/multisrc/overrides/gattsu/hentaiseason/src/HentaiSeason.kt +++ b/multisrc/overrides/gattsu/hentaiseason/src/HentaiSeason.kt @@ -8,7 +8,7 @@ import java.util.concurrent.TimeUnit class HentaiSeason : Gattsu( "Hentai Season", "https://hentaiseason.com", - "pt-BR" + "pt-BR", ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/gattsu/hentaitokyo/src/HentaiTokyo.kt b/multisrc/overrides/gattsu/hentaitokyo/src/HentaiTokyo.kt index ee4e283fd..dc05bb595 100644 --- a/multisrc/overrides/gattsu/hentaitokyo/src/HentaiTokyo.kt +++ b/multisrc/overrides/gattsu/hentaitokyo/src/HentaiTokyo.kt @@ -8,7 +8,7 @@ import java.util.concurrent.TimeUnit class HentaiTokyo : Gattsu( "Hentai Tokyo", "https://hentaitokyo.net", - "pt-BR" + "pt-BR", ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/gattsu/universohentai/src/UniversoHentai.kt b/multisrc/overrides/gattsu/universohentai/src/UniversoHentai.kt index af171e174..543966a7a 100644 --- a/multisrc/overrides/gattsu/universohentai/src/UniversoHentai.kt +++ b/multisrc/overrides/gattsu/universohentai/src/UniversoHentai.kt @@ -14,7 +14,7 @@ import java.util.concurrent.TimeUnit class UniversoHentai : Gattsu( "Universo Hentai", "https://universohentai.com", - "pt-BR" + "pt-BR", ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/gigaviewer/comicdays/src/ComicDays.kt b/multisrc/overrides/gigaviewer/comicdays/src/ComicDays.kt index 31ab4c84c..c67d5adae 100644 --- a/multisrc/overrides/gigaviewer/comicdays/src/ComicDays.kt +++ b/multisrc/overrides/gigaviewer/comicdays/src/ComicDays.kt @@ -9,7 +9,7 @@ class ComicDays : GigaViewer( "Comic Days", "https://comic-days.com", "ja", - "https://cdn-img.comic-days.com/public/page" + "https://cdn-img.comic-days.com/public/page", ) { override val client: OkHttpClient = super.client.newBuilder() @@ -30,6 +30,6 @@ class ComicDays : GigaViewer( override fun latestUpdatesSelector(): String = "section#$dayOfWeek.daily " + popularMangaSelector() override fun getCollections(): List = listOf( - Collection("連載作品一覧", "") + Collection("連載作品一覧", ""), ) } diff --git a/multisrc/overrides/gigaviewer/comicgardo/src/ComicGardo.kt b/multisrc/overrides/gigaviewer/comicgardo/src/ComicGardo.kt index ba6be3d61..b9d383fae 100644 --- a/multisrc/overrides/gigaviewer/comicgardo/src/ComicGardo.kt +++ b/multisrc/overrides/gigaviewer/comicgardo/src/ComicGardo.kt @@ -9,7 +9,7 @@ class ComicGardo : GigaViewer( "Comic Gardo", "https://comic-gardo.com", "ja", - "https://cdn-img.comic-gardo.com/public/page" + "https://cdn-img.comic-gardo.com/public/page", ) { override val supportsLatest: Boolean = false @@ -29,6 +29,6 @@ class ComicGardo : GigaViewer( } override fun getCollections(): List = listOf( - Collection("連載一覧", "") + Collection("連載一覧", ""), ) } diff --git a/multisrc/overrides/gigaviewer/comiplex/src/Comiplex.kt b/multisrc/overrides/gigaviewer/comiplex/src/Comiplex.kt index 27c6a4968..c19846f9d 100644 --- a/multisrc/overrides/gigaviewer/comiplex/src/Comiplex.kt +++ b/multisrc/overrides/gigaviewer/comiplex/src/Comiplex.kt @@ -11,7 +11,7 @@ class Comiplex : GigaViewer( "Comiplex", "https://viewer.heros-web.com", "ja", - "https://cdn-img.viewer.heros-web.com/public/page" + "https://cdn-img.viewer.heros-web.com/public/page", ) { override val supportsLatest: Boolean = false @@ -37,6 +37,6 @@ class Comiplex : GigaViewer( Collection("ヒーローズ", "heros"), Collection("ふらっとヒーローズ", "flat"), Collection("わいるどヒーローズ", "wild"), - Collection("読切作品", "oneshot") + Collection("読切作品", "oneshot"), ) } diff --git a/multisrc/overrides/gigaviewer/corocoroonline/src/CorocoroOnline.kt b/multisrc/overrides/gigaviewer/corocoroonline/src/CorocoroOnline.kt index 7d59cb263..be576e20e 100644 --- a/multisrc/overrides/gigaviewer/corocoroonline/src/CorocoroOnline.kt +++ b/multisrc/overrides/gigaviewer/corocoroonline/src/CorocoroOnline.kt @@ -15,7 +15,7 @@ class CorocoroOnline : GigaViewer( "Corocoro Online", "https://corocoro.jp", "ja", - "https://cdn-img.www.corocoro.jp/public/page" + "https://cdn-img.www.corocoro.jp/public/page", ) { override val supportsLatest: Boolean = false diff --git a/multisrc/overrides/gigaviewer/kuragebunch/src/KurageBunch.kt b/multisrc/overrides/gigaviewer/kuragebunch/src/KurageBunch.kt index 07822227a..f2a525e92 100644 --- a/multisrc/overrides/gigaviewer/kuragebunch/src/KurageBunch.kt +++ b/multisrc/overrides/gigaviewer/kuragebunch/src/KurageBunch.kt @@ -11,7 +11,7 @@ class KurageBunch : GigaViewer( "Kurage Bunch", "https://kuragebunch.com", "ja", - "https://cdn-img.kuragebunch.com" + "https://cdn-img.kuragebunch.com", ) { override val supportsLatest: Boolean = false @@ -39,6 +39,6 @@ class KurageBunch : GigaViewer( Collection("読切", "oneshot"), Collection("月刊コミックバンチ", "comicbunch"), Collection("Bバンチ", "bbunch"), - Collection("ututu", "ututu") + Collection("ututu", "ututu"), ) } diff --git a/multisrc/overrides/gigaviewer/magazinepocket/src/MagazinePocket.kt b/multisrc/overrides/gigaviewer/magazinepocket/src/MagazinePocket.kt index 24d1f586f..77ef680f6 100644 --- a/multisrc/overrides/gigaviewer/magazinepocket/src/MagazinePocket.kt +++ b/multisrc/overrides/gigaviewer/magazinepocket/src/MagazinePocket.kt @@ -9,7 +9,7 @@ class MagazinePocket : GigaViewer( "Magazine Pocket", "https://pocket.shonenmagazine.com", "ja", - "https://cdn-img.pocket.shonenmagazine.com/public/page" + "https://cdn-img.pocket.shonenmagazine.com/public/page", ) { override val client: OkHttpClient = super.client.newBuilder() @@ -31,6 +31,6 @@ class MagazinePocket : GigaViewer( override fun getCollections(): List = listOf( Collection("マガポケ連載一覧", ""), Collection("週刊少年マガジン連載一覧", "smaga"), - Collection("別冊少年マガジン連載一覧", "bmaga") + Collection("別冊少年マガジン連載一覧", "bmaga"), ) } diff --git a/multisrc/overrides/gigaviewer/magcomi/src/MagComi.kt b/multisrc/overrides/gigaviewer/magcomi/src/MagComi.kt index 20183d9fe..c17207e4d 100644 --- a/multisrc/overrides/gigaviewer/magcomi/src/MagComi.kt +++ b/multisrc/overrides/gigaviewer/magcomi/src/MagComi.kt @@ -9,7 +9,7 @@ class MagComi : GigaViewer( "MAGCOMI", "https://magcomi.com", "ja", - "https://cdn-img.magcomi.com/public/page" + "https://cdn-img.magcomi.com/public/page", ) { override val supportsLatest: Boolean = false @@ -29,6 +29,6 @@ class MagComi : GigaViewer( } override fun getCollections(): List = listOf( - Collection("連載・読切", "") + Collection("連載・読切", ""), ) } diff --git a/multisrc/overrides/gigaviewer/shonenjumpplus/src/ShonenJumpPlus.kt b/multisrc/overrides/gigaviewer/shonenjumpplus/src/ShonenJumpPlus.kt index 72cd2a811..c34222abb 100644 --- a/multisrc/overrides/gigaviewer/shonenjumpplus/src/ShonenJumpPlus.kt +++ b/multisrc/overrides/gigaviewer/shonenjumpplus/src/ShonenJumpPlus.kt @@ -7,7 +7,7 @@ class ShonenJumpPlus : GigaViewer( "Shonen Jump+", "https://shonenjumpplus.com", "ja", - "https://cdn-ak-img.shonenjumpplus.com" + "https://cdn-ak-img.shonenjumpplus.com", ) { override val client: OkHttpClient = super.client.newBuilder() @@ -19,6 +19,6 @@ class ShonenJumpPlus : GigaViewer( override fun getCollections(): List = listOf( Collection("ジャンプ+連載一覧", ""), Collection("ジャンプ+読切シリーズ", "oneshot"), - Collection("連載終了作品", "finished") + Collection("連載終了作品", "finished"), ) } diff --git a/multisrc/overrides/gigaviewer/sundaywebevery/src/SundayWebEvery.kt b/multisrc/overrides/gigaviewer/sundaywebevery/src/SundayWebEvery.kt index 989a202ed..a8d5fea94 100644 --- a/multisrc/overrides/gigaviewer/sundaywebevery/src/SundayWebEvery.kt +++ b/multisrc/overrides/gigaviewer/sundaywebevery/src/SundayWebEvery.kt @@ -9,7 +9,7 @@ class SundayWebEvery : GigaViewer( "Sunday Web Every", "https://www.sunday-webry.com", "ja", - "https://cdn-img.www.sunday-webry.com/public/page" + "https://cdn-img.www.sunday-webry.com/public/page", ) { override val client: OkHttpClient = super.client.newBuilder() @@ -33,6 +33,6 @@ class SundayWebEvery : GigaViewer( override fun getCollections(): List = listOf( Collection("連載作品", ""), Collection("読切", "oneshot"), - Collection("夜サンデー", "yoru-sunday") + Collection("夜サンデー", "yoru-sunday"), ) } diff --git a/multisrc/overrides/gigaviewer/tonarinoyoungjump/src/TonariNoYoungJump.kt b/multisrc/overrides/gigaviewer/tonarinoyoungjump/src/TonariNoYoungJump.kt index 77b7a4a5a..2ca591b87 100644 --- a/multisrc/overrides/gigaviewer/tonarinoyoungjump/src/TonariNoYoungJump.kt +++ b/multisrc/overrides/gigaviewer/tonarinoyoungjump/src/TonariNoYoungJump.kt @@ -9,7 +9,7 @@ class TonariNoYoungJump : GigaViewer( "Tonari no Young Jump", "https://tonarinoyj.jp", "ja", - "https://cdn-img.tonarinoyj.jp/public/page" + "https://cdn-img.tonarinoyj.jp/public/page", ) { override val supportsLatest: Boolean = false @@ -35,6 +35,6 @@ class TonariNoYoungJump : GigaViewer( override fun getCollections(): List = listOf( Collection("連載中", ""), Collection("読切", "oneshot"), - Collection("出張作品", "trial") + Collection("出張作品", "trial"), ) } diff --git a/multisrc/overrides/grouple/allhentai/src/AllHentai.kt b/multisrc/overrides/grouple/allhentai/src/AllHentai.kt index 092924e70..0cf0f0fcd 100644 --- a/multisrc/overrides/grouple/allhentai/src/AllHentai.kt +++ b/multisrc/overrides/grouple/allhentai/src/AllHentai.kt @@ -60,14 +60,16 @@ class AllHentai : GroupLe("AllHentai", "http://allhen.online", "ru") { else -> {} } } - return if (url.toString().contains("&")) + return if (url.toString().contains("&")) { GET(url.toString().replace("=%3D", "="), headers) - else popularMangaRequest(page) + } else { + popularMangaRequest(page) + } } private class OrderBy : Filter.Select( "Сортировка (только)", - arrayOf("Без сортировки", "По году", "По популярности", "Популярно сейчас", "По рейтингу", "Новинки", "По дате обновления") + arrayOf("Без сортировки", "По году", "По популярности", "Популярно сейчас", "По рейтингу", "Новинки", "По дате обновления"), ) private class Genre(name: String, val id: String) : Filter.TriState(name) @@ -84,7 +86,7 @@ class AllHentai : GroupLe("AllHentai", "http://allhen.online", "ru") { Tags(tagsName), GenreList(getGenreList()), Category(getCategoryList()), - FilList(getFilList()) + FilList(getFilList()), ) private fun getGenreList() = listOf( @@ -121,7 +123,7 @@ class AllHentai : GroupLe("AllHentai", "http://allhen.online", "ru") { Genre("чикан", "el_1059"), Genre("этти", "el_798"), Genre("юри", "el_84"), - Genre("яой", "el_83") + Genre("яой", "el_83"), ) private fun getCategoryList() = listOf( @@ -129,7 +131,7 @@ class AllHentai : GroupLe("AllHentai", "http://allhen.online", "ru") { Genre("Анимация", "el_5777"), Genre("Без текста", "el_3157"), Genre("Порно комикс", "el_1003"), - Genre("Порно манхва", "el_1104") + Genre("Порно манхва", "el_1104"), ) private fun getFilList() = listOf( @@ -140,7 +142,7 @@ class AllHentai : GroupLe("AllHentai", "http://allhen.online", "ru") { Genre("Переведено", "s_translated"), Genre("Длинная", "s_many_chapters"), Genre("Ожидает загрузки", "s_wait_upload"), - Genre("Продается", "s_sale") + Genre("Продается", "s_sale"), ) private fun getTagsList() = listOf( @@ -260,7 +262,7 @@ class AllHentai : GroupLe("AllHentai", "http://allhen.online", "ru") { Tag("шантаж", "blackmail"), Tag("эксгибиционизм", "exhibitionism"), Tag("эльфы", "elves"), - Tag("яндере", "yandere") + Tag("яндере", "yandere"), ) private val tagsName = getTagsList().map { diff --git a/multisrc/overrides/grouple/mintmanga/src/MintManga.kt b/multisrc/overrides/grouple/mintmanga/src/MintManga.kt index 163fada14..e21d64661 100644 --- a/multisrc/overrides/grouple/mintmanga/src/MintManga.kt +++ b/multisrc/overrides/grouple/mintmanga/src/MintManga.kt @@ -52,14 +52,16 @@ class MintManga : GroupLe("MintManga", "https://mintmanga.live", "ru") { else -> {} } } - return if (url.toString().contains("&")) + return if (url.toString().contains("&")) { GET(url.toString().replace("=%3D", "="), headers) - else popularMangaRequest(page) + } else { + popularMangaRequest(page) + } } private class OrderBy : Filter.Select( "Сортировка", - arrayOf("По популярности", "Популярно сейчас", "По году", "По имени", "Новинки", "По дате обновления", "По рейтингу") + arrayOf("По популярности", "Популярно сейчас", "По году", "По имени", "Новинки", "По дате обновления", "По рейтингу"), ) private class Genre(name: String, val id: String) : Filter.TriState(name) @@ -76,7 +78,7 @@ class MintManga : GroupLe("MintManga", "https://mintmanga.live", "ru") { GenreList(getGenreList()), AgeList(getAgeList()), More(getMore()), - FilList(getFilList()) + FilList(getFilList()), ) private fun getFilList() = listOf( Genre("Высокий рейтинг", "s_high_rate"), @@ -87,7 +89,7 @@ class MintManga : GroupLe("MintManga", "https://mintmanga.live", "ru") { Genre("Заброшен перевод", "s_abandoned_popular"), Genre("Длинная", "s_many_chapters"), Genre("Ожидает загрузки", "s_wait_upload"), - Genre("Белые жанры", "s_not_pessimized") + Genre("Белые жанры", "s_not_pessimized"), ) private fun getMore() = listOf( Genre("Анонс", "el_6641"), @@ -95,13 +97,13 @@ class MintManga : GroupLe("MintManga", "https://mintmanga.live", "ru") { Genre("Веб", "el_1355"), Genre("Выпуск приостановлен", "el_5232"), Genre("Не Яой", "el_1874"), - Genre("Сборник", "el_1348") + Genre("Сборник", "el_1348"), ) private fun getAgeList() = listOf( Genre("R(16+)", "el_3968"), Genre("NC-17(18+)", "el_3969"), - Genre("R18+(18+)", "el_3990") + Genre("R18+(18+)", "el_3990"), ) private fun getCategoryList() = listOf( @@ -113,7 +115,7 @@ class MintManga : GroupLe("MintManga", "https://mintmanga.live", "ru") { Genre("Манга", "el_6421"), Genre("Манхва", "el_1873"), Genre("Маньхуа", "el_1875"), - Genre("Ранобэ", "el_5688") + Genre("Ранобэ", "el_5688"), ) private fun getGenreList() = listOf( @@ -156,6 +158,6 @@ class MintManga : GroupLe("MintManga", "https://mintmanga.live", "ru") { Genre("эротика", "el_1340"), Genre("этти", "el_1354"), Genre("юри", "el_1315"), - Genre("яой", "el_1336") + Genre("яой", "el_1336"), ) } diff --git a/multisrc/overrides/grouple/readmanga/src/ReadManga.kt b/multisrc/overrides/grouple/readmanga/src/ReadManga.kt index ab5c7351d..c9dcf08e5 100644 --- a/multisrc/overrides/grouple/readmanga/src/ReadManga.kt +++ b/multisrc/overrides/grouple/readmanga/src/ReadManga.kt @@ -52,14 +52,16 @@ class ReadManga : GroupLe("ReadManga", "https://readmanga.live", "ru") { else -> {} } } - return if (url.toString().contains("&")) + return if (url.toString().contains("&")) { GET(url.toString().replace("=%3D", "="), headers) - else popularMangaRequest(page) + } else { + popularMangaRequest(page) + } } private class OrderBy : Filter.Select( "Сортировка", - arrayOf("По популярности", "Популярно сейчас", "По году", "По имени", "Новинки", "По дате обновления", "По рейтингу") + arrayOf("По популярности", "Популярно сейчас", "По году", "По имени", "Новинки", "По дате обновления", "По рейтингу"), ) private class Genre(name: String, val id: String) : Filter.TriState(name) @@ -76,7 +78,7 @@ class ReadManga : GroupLe("ReadManga", "https://readmanga.live", "ru") { GenreList(getGenreList()), AgeList(getAgeList()), More(getMore()), - FilList(getFilList()) + FilList(getFilList()), ) private fun getFilList() = listOf( @@ -89,19 +91,19 @@ class ReadManga : GroupLe("ReadManga", "https://readmanga.live", "ru") { Genre("Длинная", "s_many_chapters"), Genre("Ожидает загрузки", "s_wait_upload"), Genre("Продается", "s_sale"), - Genre("Белые жанры", "s_not_pessimized") + Genre("Белые жанры", "s_not_pessimized"), ) private fun getMore() = listOf( Genre("Анонс", "el_9578"), Genre("В цвете", "el_7290"), Genre("Веб", "el_2160"), - Genre("Сборник", "el_2157") + Genre("Сборник", "el_2157"), ) private fun getAgeList() = listOf( Genre("G(0+)", "el_6180"), Genre("PG-13(12+)", "el_6181"), - Genre("PG(16+)", "el_6179") + Genre("PG(16+)", "el_6179"), ) private fun getCategoryList() = listOf( @@ -112,7 +114,7 @@ class ReadManga : GroupLe("ReadManga", "https://readmanga.live", "ru") { Genre("Комикс", "el_3515"), Genre("Манга", "el_9451"), Genre("Манхва", "el_3001"), - Genre("Маньхуа", "el_3002") + Genre("Маньхуа", "el_3002"), ) private fun getGenreList() = listOf( @@ -153,6 +155,6 @@ class ReadManga : GroupLe("ReadManga", "https://readmanga.live", "ru") { Genre("уся", "el_9560"), Genre("фэнтези", "el_2131"), Genre("школа", "el_2127"), - Genre("этти", "el_2149") + Genre("этти", "el_2149"), ) } diff --git a/multisrc/overrides/grouple/rumix/src/RuMIX.kt b/multisrc/overrides/grouple/rumix/src/RuMIX.kt index f8077bb67..cbfeac84d 100644 --- a/multisrc/overrides/grouple/rumix/src/RuMIX.kt +++ b/multisrc/overrides/grouple/rumix/src/RuMIX.kt @@ -25,16 +25,18 @@ class RuMIX : GroupLe("RuMIX", "https://rumix.me", "ru") { else -> return@forEach } } - return if (url.toString().contains("&")) + return if (url.toString().contains("&")) { GET(url.toString().replace("=%3D", "="), headers) - else popularMangaRequest(page) + } else { + popularMangaRequest(page) + } } private class OrderBy : Filter.Select( "Сортировка", - arrayOf("По популярности", "Популярно сейчас", "По году", "По имени", "Новинки", "По дате обновления", "По рейтингу") + arrayOf("По популярности", "Популярно сейчас", "По году", "По имени", "Новинки", "По дате обновления", "По рейтингу"), ) override fun getFilterList() = FilterList( - OrderBy() + OrderBy(), ) } diff --git a/multisrc/overrides/grouple/selfmanga/src/SelfManga.kt b/multisrc/overrides/grouple/selfmanga/src/SelfManga.kt index 218b6aa8a..24c859028 100644 --- a/multisrc/overrides/grouple/selfmanga/src/SelfManga.kt +++ b/multisrc/overrides/grouple/selfmanga/src/SelfManga.kt @@ -37,14 +37,16 @@ class SelfManga : GroupLe("SelfManga", "https://selfmanga.live", "ru") { else -> return@forEach } } - return if (url.toString().contains("&")) + return if (url.toString().contains("&")) { GET(url.toString().replace("=%3D", "="), headers) - else popularMangaRequest(page) + } else { + popularMangaRequest(page) + } } private class OrderBy : Filter.Select( "Сортировка", - arrayOf("По популярности", "Популярно сейчас", "По году", "По имени", "Новинки", "По дате обновления", "По рейтингу") + arrayOf("По популярности", "Популярно сейчас", "По году", "По имени", "Новинки", "По дате обновления", "По рейтингу"), ) private class Genre(name: String, val id: String) : Filter.TriState(name) @@ -54,7 +56,7 @@ class SelfManga : GroupLe("SelfManga", "https://selfmanga.live", "ru") { override fun getFilterList() = FilterList( OrderBy(), Category(getCategoryList()), - GenreList(getGenreList()) + GenreList(getGenreList()), ) private fun getCategoryList() = listOf( @@ -62,7 +64,7 @@ class SelfManga : GroupLe("SelfManga", "https://selfmanga.live", "ru") { Genre("Веб", "el_2160"), Genre("Журнал", "el_4983"), Genre("Ранобэ", "el_5215"), - Genre("Сборник", "el_2157") + Genre("Сборник", "el_2157"), ) private fun getGenreList() = listOf( @@ -99,6 +101,6 @@ class SelfManga : GroupLe("SelfManga", "https://selfmanga.live", "ru") { Genre("фантастика", "el_2140"), Genre("фэнтези", "el_2131"), Genre("школа", "el_2127"), - Genre("этти", "el_4982") + Genre("этти", "el_4982"), ) } diff --git a/multisrc/overrides/guya/magicaltranslators/src/MagicalTranslators.kt b/multisrc/overrides/guya/magicaltranslators/src/MagicalTranslators.kt index f5b63435c..107ad46fa 100644 --- a/multisrc/overrides/guya/magicaltranslators/src/MagicalTranslators.kt +++ b/multisrc/overrides/guya/magicaltranslators/src/MagicalTranslators.kt @@ -36,18 +36,18 @@ abstract class MagicalTranslatorsCommon(lang: String) : class MagicalTranslatorsEN : MagicalTranslatorsCommon("en") { override fun filterMangasPage(mangasPage: MangasPage): MangasPage = mangasPage.copy( - mangas = mangasPage.mangas.filterNot { it.url.endsWith("-ES") || it.url.endsWith("-PL") } + mangas = mangasPage.mangas.filterNot { it.url.endsWith("-ES") || it.url.endsWith("-PL") }, ) } class MagicalTranslatorsES : MagicalTranslatorsCommon("es") { override fun filterMangasPage(mangasPage: MangasPage): MangasPage = mangasPage.copy( - mangas = mangasPage.mangas.filter { it.url.endsWith("-ES") } + mangas = mangasPage.mangas.filter { it.url.endsWith("-ES") }, ) } class MagicalTranslatorsPL : MagicalTranslatorsCommon("pl") { override fun filterMangasPage(mangasPage: MangasPage): MangasPage = mangasPage.copy( - mangas = mangasPage.mangas.filter { it.url.endsWith("-PL") } + mangas = mangasPage.mangas.filter { it.url.endsWith("-PL") }, ) } diff --git a/multisrc/overrides/heancms/reaperscans/src/ReaperScans.kt b/multisrc/overrides/heancms/reaperscans/src/ReaperScans.kt index b631c6a3a..78e494d92 100644 --- a/multisrc/overrides/heancms/reaperscans/src/ReaperScans.kt +++ b/multisrc/overrides/heancms/reaperscans/src/ReaperScans.kt @@ -11,7 +11,7 @@ import java.util.TimeZone class ReaperScans : HeanCms( "Reaper Scans", "https://reaperscans.net", - "pt-BR" + "pt-BR", ) { override val client: OkHttpClient = super.client.newBuilder() @@ -51,6 +51,6 @@ class ReaperScans : HeanCms( Genre("Segunda vida", 4), Genre("Seinen", 1), Genre("Shounen", 13), - Genre("Terror", 6) + Genre("Terror", 6), ) } diff --git a/multisrc/overrides/heancms/yugenmangas/src/YugenMangas.kt b/multisrc/overrides/heancms/yugenmangas/src/YugenMangas.kt index 6c5d1a8a4..d687af555 100644 --- a/multisrc/overrides/heancms/yugenmangas/src/YugenMangas.kt +++ b/multisrc/overrides/heancms/yugenmangas/src/YugenMangas.kt @@ -9,7 +9,7 @@ class YugenMangas : HeanCms( "YugenMangas", "https://yugenmangas.net", "es", - "https://api.yugenmangas.com" + "https://api.yugenmangas.com", ) { // Site changed from Madara to HeanCms. @@ -69,6 +69,6 @@ class YugenMangas : HeanCms( Genre("Transmigración", 34), Genre("Vida Escolar", 47), Genre("Yaoi", 43), - Genre("Yuri", 44) + Genre("Yuri", 44), ) } diff --git a/multisrc/overrides/libgroup/hentailib/src/HentaiLib.kt b/multisrc/overrides/libgroup/hentailib/src/HentaiLib.kt index 888d82d8c..a8219f6f2 100644 --- a/multisrc/overrides/libgroup/hentailib/src/HentaiLib.kt +++ b/multisrc/overrides/libgroup/hentailib/src/HentaiLib.kt @@ -39,7 +39,7 @@ class HentaiLib : LibGroup("HentaiLib", "https://hentailib.me", "ru") { if (tag.state != Filter.TriState.STATE_IGNORE) { url.addQueryParameter( if (tag.isIncluded()) "tags[include][]" else "tags[exclude][]", - tag.id + tag.id, ) } } @@ -226,7 +226,7 @@ class HentaiLib : LibGroup("HentaiLib", "https://hentailib.me", "ru") { SearchFilter("Эксгибиционизм", "143"), SearchFilter("Эльф", "144"), SearchFilter("Юные", "145"), - SearchFilter("Яндэрэ", "146") + SearchFilter("Яндэрэ", "146"), ) companion object { diff --git a/multisrc/overrides/libgroup/mangalib/src/MangaLib.kt b/multisrc/overrides/libgroup/mangalib/src/MangaLib.kt index 4d8019f31..8bce9f001 100644 --- a/multisrc/overrides/libgroup/mangalib/src/MangaLib.kt +++ b/multisrc/overrides/libgroup/mangalib/src/MangaLib.kt @@ -55,7 +55,7 @@ class MangaLib : LibGroup("MangaLib", "https://mangalib.me", "ru") { if (age.state != Filter.TriState.STATE_IGNORE) { url.addQueryParameter( if (age.isIncluded()) "caution[include][]" else "caution[exclude][]", - age.id + age.id, ) } } @@ -63,7 +63,7 @@ class MangaLib : LibGroup("MangaLib", "https://mangalib.me", "ru") { if (tag.state != Filter.TriState.STATE_IGNORE) { url.addQueryParameter( if (tag.isIncluded()) "tags[include][]" else "tags[exclude][]", - tag.id + tag.id, ) } } @@ -183,14 +183,14 @@ class MangaLib : LibGroup("MangaLib", "https://mangalib.me", "ru") { SearchFilter("Шантаж", "279"), SearchFilter("Эльфы", "216"), SearchFilter("Якудза", "164"), - SearchFilter("Япония", "280") + SearchFilter("Япония", "280"), ) private fun getAgeList() = listOf( SearchFilter("Отсутствует", "0"), SearchFilter("16+", "1"), - SearchFilter("18+", "2") + SearchFilter("18+", "2"), ) companion object { diff --git a/multisrc/overrides/libgroup/yaoilib/src/YaoiLib.kt b/multisrc/overrides/libgroup/yaoilib/src/YaoiLib.kt index f8659488b..b559b8c26 100644 --- a/multisrc/overrides/libgroup/yaoilib/src/YaoiLib.kt +++ b/multisrc/overrides/libgroup/yaoilib/src/YaoiLib.kt @@ -37,7 +37,7 @@ class YaoiLib : LibGroup("YaoiLib", "https://v1.yaoilib.net", "ru") { if (age.state != Filter.TriState.STATE_IGNORE) { url.addQueryParameter( if (age.isIncluded()) "caution[include][]" else "caution[exclude][]", - age.id + age.id, ) } } @@ -45,7 +45,7 @@ class YaoiLib : LibGroup("YaoiLib", "https://v1.yaoilib.net", "ru") { if (tag.state != Filter.TriState.STATE_IGNORE) { url.addQueryParameter( if (tag.isIncluded()) "tags[include][]" else "tags[exclude][]", - tag.id + tag.id, ) } } @@ -165,14 +165,14 @@ class YaoiLib : LibGroup("YaoiLib", "https://v1.yaoilib.net", "ru") { SearchFilter("Шантаж", "279"), SearchFilter("Эльфы", "216"), SearchFilter("Якудза", "164"), - SearchFilter("Япония", "280") + SearchFilter("Япония", "280"), ) private fun getAgeList() = listOf( SearchFilter("Отсутствует", "0"), SearchFilter("16+", "1"), - SearchFilter("18+", "2") + SearchFilter("18+", "2"), ) companion object { diff --git a/multisrc/overrides/madara/adultwebtoon/src/AdultWebtoon.kt b/multisrc/overrides/madara/adultwebtoon/src/AdultWebtoon.kt index 0f9fcb691..c0e0698f6 100644 --- a/multisrc/overrides/madara/adultwebtoon/src/AdultWebtoon.kt +++ b/multisrc/overrides/madara/adultwebtoon/src/AdultWebtoon.kt @@ -13,7 +13,7 @@ class AdultWebtoon : Madara("Adult Webtoon", "https://adultwebtoon.com", "en") { return GET( "$baseUrl/manga/$pageSuffix?m_orderby=trending", formHeaders, - CacheControl.FORCE_NETWORK + CacheControl.FORCE_NETWORK, ) } override fun latestUpdatesRequest(page: Int): Request { @@ -21,7 +21,7 @@ class AdultWebtoon : Madara("Adult Webtoon", "https://adultwebtoon.com", "en") { return GET( "$baseUrl/manga/$pageSuffix?m_orderby=latest", formHeaders, - CacheControl.FORCE_NETWORK + CacheControl.FORCE_NETWORK, ) } } diff --git a/multisrc/overrides/madara/aiyumanga/src/AiYuManga.kt b/multisrc/overrides/madara/aiyumanga/src/AiYuManga.kt index 3fe14be0b..72ab46c2d 100644 --- a/multisrc/overrides/madara/aiyumanga/src/AiYuManga.kt +++ b/multisrc/overrides/madara/aiyumanga/src/AiYuManga.kt @@ -8,7 +8,7 @@ class AiYuManga : Madara( "AiYuManga", "https://aiyumangascanlation.com", "es", - SimpleDateFormat("d 'de' MMM 'de' yyy", Locale("es")) + SimpleDateFormat("d 'de' MMM 'de' yyy", Locale("es")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/akumanotenshi/src/AkumaNoTenshi.kt b/multisrc/overrides/madara/akumanotenshi/src/AkumaNoTenshi.kt index 570abcbf2..e8d319261 100644 --- a/multisrc/overrides/madara/akumanotenshi/src/AkumaNoTenshi.kt +++ b/multisrc/overrides/madara/akumanotenshi/src/AkumaNoTenshi.kt @@ -11,7 +11,7 @@ class AkumaNoTenshi : Madara( "Akuma no Tenshi", "https://akumanotenshi.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/aleatoriascan/src/AleatoriaScan.kt b/multisrc/overrides/madara/aleatoriascan/src/AleatoriaScan.kt index d8ccc5c4d..d94100175 100644 --- a/multisrc/overrides/madara/aleatoriascan/src/AleatoriaScan.kt +++ b/multisrc/overrides/madara/aleatoriascan/src/AleatoriaScan.kt @@ -11,7 +11,7 @@ class AleatoriaScan : Madara( "Aleatória Scan", "https://aleatoriascan.xyz", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/amuy/src/Amuy.kt b/multisrc/overrides/madara/amuy/src/Amuy.kt index e74c3c6e9..a326c14a7 100644 --- a/multisrc/overrides/madara/amuy/src/Amuy.kt +++ b/multisrc/overrides/madara/amuy/src/Amuy.kt @@ -18,7 +18,7 @@ class Amuy : Madara( "Amuy", "https://amuyscans.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() @@ -38,7 +38,7 @@ class Amuy : Madara( chapterProtector .substringAfter("chapter_data='") .substringBefore("';") - .replace("\\/", "/") + .replace("\\/", "/"), ).jsonObject val unsaltedCiphertext = Base64.decode(chapterData["ct"]!!.jsonPrimitive.content, Base64.DEFAULT) diff --git a/multisrc/overrides/madara/arabtoons/src/ArabToons.kt b/multisrc/overrides/madara/arabtoons/src/ArabToons.kt index 54ea25b83..9acadf3a2 100644 --- a/multisrc/overrides/madara/arabtoons/src/ArabToons.kt +++ b/multisrc/overrides/madara/arabtoons/src/ArabToons.kt @@ -8,7 +8,7 @@ class ArabToons : Madara( "عرب تونز", "https://arabtoons.net", "ar", - dateFormat = SimpleDateFormat("MMM d", Locale("ar")) + dateFormat = SimpleDateFormat("MMM d", Locale("ar")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/arthurscan/src/ArthurScan.kt b/multisrc/overrides/madara/arthurscan/src/ArthurScan.kt index 2214e064e..afa7a762f 100644 --- a/multisrc/overrides/madara/arthurscan/src/ArthurScan.kt +++ b/multisrc/overrides/madara/arthurscan/src/ArthurScan.kt @@ -11,7 +11,7 @@ class ArthurScan : Madara( "Arthur Scan", "https://arthurscan.xyz", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/bananamecanica/src/BananaCitrica.kt b/multisrc/overrides/madara/bananamecanica/src/BananaCitrica.kt index 96b701fb3..07f453b2c 100644 --- a/multisrc/overrides/madara/bananamecanica/src/BananaCitrica.kt +++ b/multisrc/overrides/madara/bananamecanica/src/BananaCitrica.kt @@ -11,7 +11,7 @@ class BananaCitrica : Madara( "Banana Cítrica", "https://dinastiacilly.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { // Website changed their name. diff --git a/multisrc/overrides/madara/bichentraducoes/src/BichenTraducoes.kt b/multisrc/overrides/madara/bichentraducoes/src/BichenTraducoes.kt index c00eb407e..e5aac81ff 100644 --- a/multisrc/overrides/madara/bichentraducoes/src/BichenTraducoes.kt +++ b/multisrc/overrides/madara/bichentraducoes/src/BichenTraducoes.kt @@ -11,7 +11,7 @@ class BichenTraducoes : Madara( "Bichen Traduções", "https://bichentraducoes.com", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/blmanhwaclub/src/BlManhwaClub.kt b/multisrc/overrides/madara/blmanhwaclub/src/BlManhwaClub.kt index 118ee24ae..f08f396f2 100644 --- a/multisrc/overrides/madara/blmanhwaclub/src/BlManhwaClub.kt +++ b/multisrc/overrides/madara/blmanhwaclub/src/BlManhwaClub.kt @@ -11,7 +11,7 @@ class BlManhwaClub : Madara( "BL Manhwa Club", "https://blmanhwa.club", "pt-BR", - SimpleDateFormat("dd MMM yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd MMM yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/borutoexplorer/src/BorutoExplorer.kt b/multisrc/overrides/madara/borutoexplorer/src/BorutoExplorer.kt index e6cc3c05a..d9968b166 100644 --- a/multisrc/overrides/madara/borutoexplorer/src/BorutoExplorer.kt +++ b/multisrc/overrides/madara/borutoexplorer/src/BorutoExplorer.kt @@ -11,7 +11,7 @@ class BorutoExplorer : Madara( "Boruto Explorer", "https://leitor.borutoexplorer.com.br", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/cafecomyaoi/src/CafeComYaoi.kt b/multisrc/overrides/madara/cafecomyaoi/src/CafeComYaoi.kt index fea9b13fd..5323d04b5 100644 --- a/multisrc/overrides/madara/cafecomyaoi/src/CafeComYaoi.kt +++ b/multisrc/overrides/madara/cafecomyaoi/src/CafeComYaoi.kt @@ -11,7 +11,7 @@ class CafeComYaoi : Madara( "Café com Yaoi", "http://cafecomyaoi.com.br", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/cattranslator/src/CatTranslator.kt b/multisrc/overrides/madara/cattranslator/src/CatTranslator.kt index 745974189..02547066c 100644 --- a/multisrc/overrides/madara/cattranslator/src/CatTranslator.kt +++ b/multisrc/overrides/madara/cattranslator/src/CatTranslator.kt @@ -7,7 +7,7 @@ import org.jsoup.nodes.Element class CatTranslator : Madara( "CAT-translator", "https://cats-translator.com/manga", - "th" + "th", ) { private fun parseMangaFromElement(element: Element, isSearch: Boolean): SManga { val manga = SManga.create() diff --git a/multisrc/overrides/madara/cerisescans/src/CeriseScans.kt b/multisrc/overrides/madara/cerisescans/src/CeriseScans.kt index b4cb46355..3c71a6c62 100644 --- a/multisrc/overrides/madara/cerisescans/src/CeriseScans.kt +++ b/multisrc/overrides/madara/cerisescans/src/CeriseScans.kt @@ -18,7 +18,7 @@ class CeriseScans : Madara( "Cerise Scans", "https://cerisescan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() @@ -38,7 +38,7 @@ class CeriseScans : Madara( chapterProtector .substringAfter("chapter_data='") .substringBefore("';") - .replace("\\/", "/") + .replace("\\/", "/"), ).jsonObject val unsaltedCiphertext = Base64.decode(chapterData["ct"]!!.jsonPrimitive.content, Base64.DEFAULT) diff --git a/multisrc/overrides/madara/chunchunmarutranslations/src/ChunchunmaruTranslations.kt b/multisrc/overrides/madara/chunchunmarutranslations/src/ChunchunmaruTranslations.kt index 3b38fcc1c..53a71287c 100644 --- a/multisrc/overrides/madara/chunchunmarutranslations/src/ChunchunmaruTranslations.kt +++ b/multisrc/overrides/madara/chunchunmarutranslations/src/ChunchunmaruTranslations.kt @@ -13,7 +13,7 @@ class ChunchunmaruTranslations : Madara( "Chunchunmaru Translations", "https://chunchunmarutl.com", "es", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("es")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("es")), ) { override fun popularMangaRequest(page: Int): Request = GET("$baseUrl/manga/page/$page/?m_orderby=views", headers) diff --git a/multisrc/overrides/madara/cronosscan/src/CronosScan.kt b/multisrc/overrides/madara/cronosscan/src/CronosScan.kt index 855a9e8a6..8ed0a6aac 100644 --- a/multisrc/overrides/madara/cronosscan/src/CronosScan.kt +++ b/multisrc/overrides/madara/cronosscan/src/CronosScan.kt @@ -11,7 +11,7 @@ class CronosScan : Madara( "Cronos Scan", "https://cronosscan.net", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/daprob/src/DapRob.kt b/multisrc/overrides/madara/daprob/src/DapRob.kt index ee3039cc0..ce39b7c3f 100644 --- a/multisrc/overrides/madara/daprob/src/DapRob.kt +++ b/multisrc/overrides/madara/daprob/src/DapRob.kt @@ -8,7 +8,7 @@ class DapRob : Madara( "DapRob", "https://daprob.com", "es", - dateFormat = SimpleDateFormat("dd/MM/yyy", Locale.ROOT) + dateFormat = SimpleDateFormat("dd/MM/yyy", Locale.ROOT), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/doujinhentai/src/DoujinHentai.kt b/multisrc/overrides/madara/doujinhentai/src/DoujinHentai.kt index d6f3d2791..70a749d18 100644 --- a/multisrc/overrides/madara/doujinhentai/src/DoujinHentai.kt +++ b/multisrc/overrides/madara/doujinhentai/src/DoujinHentai.kt @@ -15,7 +15,7 @@ class DoujinHentai : Madara( "DoujinHentai", "https://doujinhentai.net", "es", - SimpleDateFormat("d MMM. yyyy", Locale.ENGLISH) + SimpleDateFormat("d MMM. yyyy", Locale.ENGLISH), ) { override val useLoadMoreSearch = false @@ -71,7 +71,7 @@ class DoujinHentai : Madara( override fun getFilterList() = FilterList( Filter.Header("Solo funciona si la consulta está en blanco"), - GenreSelectFilter() + GenreSelectFilter(), ) class GenreSelectFilter : UriPartFilter( @@ -109,7 +109,7 @@ class DoujinHentai : Madara( Pair("Sin Censura", "sin-censura"), Pair("Futanari", "futanari"), Pair("Doble Penetracion", "doble-penetracion"), - Pair("Cosplay", "cosplay") - ) + Pair("Cosplay", "cosplay"), + ), ) } diff --git a/multisrc/overrides/madara/dropescan/src/DropeScan.kt b/multisrc/overrides/madara/dropescan/src/DropeScan.kt index 1f51d2ba6..b777e1e32 100644 --- a/multisrc/overrides/madara/dropescan/src/DropeScan.kt +++ b/multisrc/overrides/madara/dropescan/src/DropeScan.kt @@ -13,7 +13,7 @@ class DropeScan : Madara( "Drope Scan", "https://dropescan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/egymanga/src/EGYManga.kt b/multisrc/overrides/madara/egymanga/src/EGYManga.kt index eebb927e7..51450ca47 100644 --- a/multisrc/overrides/madara/egymanga/src/EGYManga.kt +++ b/multisrc/overrides/madara/egymanga/src/EGYManga.kt @@ -10,7 +10,7 @@ class EGYManga : Madara( "EGY Manga", "https://egymanga.net", "ar", - SimpleDateFormat("MMMM dd, yyyy", Locale("ar")) + SimpleDateFormat("MMMM dd, yyyy", Locale("ar")), ) { // The website does not flag the content. diff --git a/multisrc/overrides/madara/eromiau/src/Eromiau.kt b/multisrc/overrides/madara/eromiau/src/Eromiau.kt index 88853c2b1..90f1583dd 100644 --- a/multisrc/overrides/madara/eromiau/src/Eromiau.kt +++ b/multisrc/overrides/madara/eromiau/src/Eromiau.kt @@ -8,7 +8,7 @@ class Eromiau : Madara( "Eromiau", "https://www.eromiau.com", "es", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("es")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("es")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/estufadecristal/src/EstufaDeCristal.kt b/multisrc/overrides/madara/estufadecristal/src/EstufaDeCristal.kt index 7e523cad6..d1b598411 100644 --- a/multisrc/overrides/madara/estufadecristal/src/EstufaDeCristal.kt +++ b/multisrc/overrides/madara/estufadecristal/src/EstufaDeCristal.kt @@ -13,7 +13,7 @@ class EstufaDeCristal : Madara( "Estufa de Cristal", "https://scanestufadecristal.site", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/evascans/src/EvaScans.kt b/multisrc/overrides/madara/evascans/src/EvaScans.kt index 629be450c..d76c36a85 100644 --- a/multisrc/overrides/madara/evascans/src/EvaScans.kt +++ b/multisrc/overrides/madara/evascans/src/EvaScans.kt @@ -8,7 +8,7 @@ class EvaScans : Madara( "EvaScans", "https://evascans.com", "tr", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")), ) { override val useNewChapterEndpoint = false } diff --git a/multisrc/overrides/madara/faestorm/src/FaeStorm.kt b/multisrc/overrides/madara/faestorm/src/FaeStorm.kt index aea55d741..aa5fc045b 100644 --- a/multisrc/overrides/madara/faestorm/src/FaeStorm.kt +++ b/multisrc/overrides/madara/faestorm/src/FaeStorm.kt @@ -8,5 +8,5 @@ class FaeStorm : Madara( "FaeStorm", "https://faestormmanga.com", "tr", - SimpleDateFormat("d MMM yyy", Locale("tr")) + SimpleDateFormat("d MMM yyy", Locale("tr")), ) diff --git a/multisrc/overrides/madara/fayscans/src/FayScans.kt b/multisrc/overrides/madara/fayscans/src/FayScans.kt index 25646026f..33127d7a7 100644 --- a/multisrc/overrides/madara/fayscans/src/FayScans.kt +++ b/multisrc/overrides/madara/fayscans/src/FayScans.kt @@ -11,7 +11,7 @@ class FayScans : Madara( "Fay Scans", "https://fayscans.com.br", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/fdmscan/src/FDMScan.kt b/multisrc/overrides/madara/fdmscan/src/FDMScan.kt index d66cbf199..b689a8490 100644 --- a/multisrc/overrides/madara/fdmscan/src/FDMScan.kt +++ b/multisrc/overrides/madara/fdmscan/src/FDMScan.kt @@ -11,7 +11,7 @@ class FDMScan : Madara( "FDM Scan", "https://fdmscan.com", "pt-BR", - SimpleDateFormat("MMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/finalscans/src/FinalScans.kt b/multisrc/overrides/madara/finalscans/src/FinalScans.kt index c1f5a318e..74c74fe1c 100644 --- a/multisrc/overrides/madara/finalscans/src/FinalScans.kt +++ b/multisrc/overrides/madara/finalscans/src/FinalScans.kt @@ -11,7 +11,7 @@ class FinalScans : Madara( "Final Scans", "https://finalscans.com", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/firstkissmanga/src/FirstKissManga.kt b/multisrc/overrides/madara/firstkissmanga/src/FirstKissManga.kt index e38ef894c..1a26b5a85 100644 --- a/multisrc/overrides/madara/firstkissmanga/src/FirstKissManga.kt +++ b/multisrc/overrides/madara/firstkissmanga/src/FirstKissManga.kt @@ -8,7 +8,7 @@ import java.util.concurrent.TimeUnit class FirstKissManga : Madara( "1st Kiss", "https://1stkissmanga.io", - "en" + "en", ) { override fun headersBuilder(): Headers.Builder = super.headersBuilder().add("Referer", baseUrl) diff --git a/multisrc/overrides/madara/firstkissmangaclub/src/FirstKissMangaClub.kt b/multisrc/overrides/madara/firstkissmangaclub/src/FirstKissMangaClub.kt index aa1a6c20b..71b2e1916 100644 --- a/multisrc/overrides/madara/firstkissmangaclub/src/FirstKissMangaClub.kt +++ b/multisrc/overrides/madara/firstkissmangaclub/src/FirstKissMangaClub.kt @@ -7,7 +7,7 @@ import java.util.concurrent.TimeUnit class FirstKissMangaClub : Madara( "1stKissManga.Club", "https://1stkissmanga.club", - "en" + "en", ) { override val client = network.cloudflareClient.newBuilder() diff --git a/multisrc/overrides/madara/firstkissmangalove/src/FirstKissMangaLove.kt b/multisrc/overrides/madara/firstkissmangalove/src/FirstKissMangaLove.kt index 078e524b6..3e4ce1588 100644 --- a/multisrc/overrides/madara/firstkissmangalove/src/FirstKissMangaLove.kt +++ b/multisrc/overrides/madara/firstkissmangalove/src/FirstKissMangaLove.kt @@ -7,7 +7,7 @@ import java.util.concurrent.TimeUnit class FirstKissMangaLove : Madara( "1st Kiss Manga.love", "https://1stkissmanga.love", - "en" + "en", ) { override val client = network.cloudflareClient.newBuilder() diff --git a/multisrc/overrides/madara/firstkissmanhua/src/FirstKissManhua.kt b/multisrc/overrides/madara/firstkissmanhua/src/FirstKissManhua.kt index 9a096a8ba..9afdeb94f 100644 --- a/multisrc/overrides/madara/firstkissmanhua/src/FirstKissManhua.kt +++ b/multisrc/overrides/madara/firstkissmanhua/src/FirstKissManhua.kt @@ -13,7 +13,7 @@ class FirstKissManhua : Madara( "1st Kiss Manhua", "https://1stkissmanhua.com", "en", - SimpleDateFormat("d MMM yyyy", Locale.US) + SimpleDateFormat("d MMM yyyy", Locale.US), ) { override val client = network.cloudflareClient.newBuilder() diff --git a/multisrc/overrides/madara/fleurblanche/src/FleurBlanche.kt b/multisrc/overrides/madara/fleurblanche/src/FleurBlanche.kt index 3abd9af21..5f3635289 100644 --- a/multisrc/overrides/madara/fleurblanche/src/FleurBlanche.kt +++ b/multisrc/overrides/madara/fleurblanche/src/FleurBlanche.kt @@ -15,7 +15,7 @@ class FleurBlanche : Madara( "Fleur Blanche", "https://fbsquads.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/flextapescans/src/FlexTapeScans.kt b/multisrc/overrides/madara/flextapescans/src/FlexTapeScans.kt index b35e7f128..d78e6fe8a 100644 --- a/multisrc/overrides/madara/flextapescans/src/FlexTapeScans.kt +++ b/multisrc/overrides/madara/flextapescans/src/FlexTapeScans.kt @@ -10,7 +10,7 @@ class FlexTapeScans : Madara( "Flex Tape Scans", "https://flextapescans.com", "en", - dateFormat = SimpleDateFormat("MM/dd/yyy", Locale.ROOT) + dateFormat = SimpleDateFormat("MM/dd/yyy", Locale.ROOT), ) { override val useNewChapterEndpoint = false diff --git a/multisrc/overrides/madara/foxwhite/src/FoxWhite.kt b/multisrc/overrides/madara/foxwhite/src/FoxWhite.kt index df83f39b8..648be28e2 100644 --- a/multisrc/overrides/madara/foxwhite/src/FoxWhite.kt +++ b/multisrc/overrides/madara/foxwhite/src/FoxWhite.kt @@ -11,7 +11,7 @@ class FoxWhite : Madara( "Fox White", "https://foxwhite.com.br", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/fukushuunoyuusha/src/FukushuunoYuusha.kt b/multisrc/overrides/madara/fukushuunoyuusha/src/FukushuunoYuusha.kt index 668f66478..5d86ca129 100644 --- a/multisrc/overrides/madara/fukushuunoyuusha/src/FukushuunoYuusha.kt +++ b/multisrc/overrides/madara/fukushuunoyuusha/src/FukushuunoYuusha.kt @@ -5,6 +5,8 @@ import java.text.SimpleDateFormat import java.util.Locale class FukushuunoYuusha : Madara( - "Fukushuu no Yuusha", "https://fny-scantrad.com", - "fr", dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US) + "Fukushuu no Yuusha", + "https://fny-scantrad.com", + "fr", + dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US), ) diff --git a/multisrc/overrides/madara/furioscans/src/FurioScans.kt b/multisrc/overrides/madara/furioscans/src/FurioScans.kt index a130a230a..2436dc4de 100644 --- a/multisrc/overrides/madara/furioscans/src/FurioScans.kt +++ b/multisrc/overrides/madara/furioscans/src/FurioScans.kt @@ -11,7 +11,7 @@ class FurioScans : Madara( "Furio Scans", "https://furioscans.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/geasstoon/src/GeassToon.kt b/multisrc/overrides/madara/geasstoon/src/GeassToon.kt index f65314349..414eb2716 100644 --- a/multisrc/overrides/madara/geasstoon/src/GeassToon.kt +++ b/multisrc/overrides/madara/geasstoon/src/GeassToon.kt @@ -8,7 +8,7 @@ class GeassToon : Madara( "GeassToon", "https://geasstoon.com", "tr", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/geceninlordu/src/GeceninLordu.kt b/multisrc/overrides/madara/geceninlordu/src/GeceninLordu.kt index fbe4744d3..3bf85b233 100644 --- a/multisrc/overrides/madara/geceninlordu/src/GeceninLordu.kt +++ b/multisrc/overrides/madara/geceninlordu/src/GeceninLordu.kt @@ -10,7 +10,7 @@ class GeceninLordu : Madara( "Gecenin Lordu", "https://geceninlordu.com/", "tr", - SimpleDateFormat("dd MMM yyyy", Locale("tr")) + SimpleDateFormat("dd MMM yyyy", Locale("tr")), ) { override val useLoadMoreSearch = false diff --git a/multisrc/overrides/madara/gloriousscan/src/GloriousScan.kt b/multisrc/overrides/madara/gloriousscan/src/GloriousScan.kt index f5bbcbfd5..ab0ea7014 100644 --- a/multisrc/overrides/madara/gloriousscan/src/GloriousScan.kt +++ b/multisrc/overrides/madara/gloriousscan/src/GloriousScan.kt @@ -11,7 +11,7 @@ class GloriousScan : Madara( "Glorious Scan", "https://gloriousscan.com", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/glorymanga/src/GloryManga.kt b/multisrc/overrides/madara/glorymanga/src/GloryManga.kt index 71165906a..4f5f4e567 100644 --- a/multisrc/overrides/madara/glorymanga/src/GloryManga.kt +++ b/multisrc/overrides/madara/glorymanga/src/GloryManga.kt @@ -8,7 +8,7 @@ class GloryManga : Madara( "Glory Manga", "https://glorymanga.com", "tr", - dateFormat = SimpleDateFormat("dd/MM/yyy", Locale.ROOT) + dateFormat = SimpleDateFormat("dd/MM/yyy", Locale.ROOT), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/gloryscans/src/GloryScans.kt b/multisrc/overrides/madara/gloryscans/src/GloryScans.kt index d0bfcff96..d624a2050 100644 --- a/multisrc/overrides/madara/gloryscans/src/GloryScans.kt +++ b/multisrc/overrides/madara/gloryscans/src/GloryScans.kt @@ -8,7 +8,7 @@ class GloryScans : Madara( "Glory Scans", "https://gloryscans.com", "tr", - dateFormat = SimpleDateFormat("d MMM yyy", Locale("tr")) + dateFormat = SimpleDateFormat("d MMM yyy", Locale("tr")), ) { override val useNewChapterEndpoint = false } diff --git a/multisrc/overrides/madara/gooffansub/src/GoofFansub.kt b/multisrc/overrides/madara/gooffansub/src/GoofFansub.kt index 10fa148ad..dcac12728 100644 --- a/multisrc/overrides/madara/gooffansub/src/GoofFansub.kt +++ b/multisrc/overrides/madara/gooffansub/src/GoofFansub.kt @@ -11,7 +11,7 @@ class GoofFansub : Madara( "Goof Fansub", "https://gooffansub.com", "pt-BR", - SimpleDateFormat("dd/MM/yyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/hattorimanga/src/HattoriManga.kt b/multisrc/overrides/madara/hattorimanga/src/HattoriManga.kt index ca94f0b9b..d59f0f2f4 100644 --- a/multisrc/overrides/madara/hattorimanga/src/HattoriManga.kt +++ b/multisrc/overrides/madara/hattorimanga/src/HattoriManga.kt @@ -10,7 +10,7 @@ class HattoriManga : Madara( "Hattori Manga", "https://hattorimanga.com", "tr", - SimpleDateFormat("d MMM yyy", Locale("tr")) + SimpleDateFormat("d MMM yyy", Locale("tr")), ) { override fun pageListParse(document: Document): List { val blocked = document.select(".content-blocked").first() diff --git a/multisrc/overrides/madara/helascan/src/HelaScan.kt b/multisrc/overrides/madara/helascan/src/HelaScan.kt index c06a30336..f6914e279 100644 --- a/multisrc/overrides/madara/helascan/src/HelaScan.kt +++ b/multisrc/overrides/madara/helascan/src/HelaScan.kt @@ -11,7 +11,7 @@ class HelaScan : Madara( "Hela Scan", "https://helascan.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/hentaicube/src/HentaiCB.kt b/multisrc/overrides/madara/hentaicube/src/HentaiCB.kt index 781dfa91e..0a3cd57d7 100644 --- a/multisrc/overrides/madara/hentaicube/src/HentaiCB.kt +++ b/multisrc/overrides/madara/hentaicube/src/HentaiCB.kt @@ -19,14 +19,14 @@ class HentaiCB : Madara("Hentai CB", "https://hentaicb.xyz", "vi", SimpleDateFor return GET( "$baseUrl/manga/page/$page/?m_orderby=views", formHeaders, - CacheControl.FORCE_NETWORK + CacheControl.FORCE_NETWORK, ) } override fun latestUpdatesRequest(page: Int): Request { return GET( "$baseUrl/manga/page/$page/?m_orderby=latest", formHeaders, - CacheControl.FORCE_NETWORK + CacheControl.FORCE_NETWORK, ) } } diff --git a/multisrc/overrides/madara/hentaimanga/src/HentaiManga.kt b/multisrc/overrides/madara/hentaimanga/src/HentaiManga.kt index 43b241091..bbdeaf1c2 100644 --- a/multisrc/overrides/madara/hentaimanga/src/HentaiManga.kt +++ b/multisrc/overrides/madara/hentaimanga/src/HentaiManga.kt @@ -8,7 +8,7 @@ class HentaiManga : Madara( "Hentai Manga", "https://hentaimanga.me", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) { // The website does not flag the content. diff --git a/multisrc/overrides/madara/hentairead/src/Hentairead.kt b/multisrc/overrides/madara/hentairead/src/Hentairead.kt index 3e367ae38..9f80bf97a 100644 --- a/multisrc/overrides/madara/hentairead/src/Hentairead.kt +++ b/multisrc/overrides/madara/hentairead/src/Hentairead.kt @@ -32,7 +32,7 @@ class Hentairead : Madara("HentaiRead", "https://hentairead.com", "en", dateForm index, document.location(), Uri.parse(pageUri).buildUpon().clearQuery().appendQueryParameter("ssl", "1") - .appendQueryParameter("w", "1100").build().toString() + .appendQueryParameter("w", "1100").build().toString(), ) } } @@ -42,7 +42,7 @@ class Hentairead : Madara("HentaiRead", "https://hentairead.com", "en", dateForm SChapter.create().apply { name = "Chapter" setUrlWithoutDomain(response.request.url.encodedPath) - } + }, ) } } diff --git a/multisrc/overrides/madara/hentaiteca/src/HentaiTeca.kt b/multisrc/overrides/madara/hentaiteca/src/HentaiTeca.kt index a58338d13..5689d18f5 100644 --- a/multisrc/overrides/madara/hentaiteca/src/HentaiTeca.kt +++ b/multisrc/overrides/madara/hentaiteca/src/HentaiTeca.kt @@ -12,7 +12,7 @@ class HentaiTeca : Madara( "Hentai Teca", "https://hentaiteca.net", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/hentaixcomic/src/HentaiXComic.kt b/multisrc/overrides/madara/hentaixcomic/src/HentaiXComic.kt index 8aab57912..3f0d0296c 100644 --- a/multisrc/overrides/madara/hentaixcomic/src/HentaiXComic.kt +++ b/multisrc/overrides/madara/hentaixcomic/src/HentaiXComic.kt @@ -8,5 +8,5 @@ class HentaiXComic : Madara( "HentaiXComic", "https://hentaixcomic.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/hentaixyuri/src/HentaiXYuri.kt b/multisrc/overrides/madara/hentaixyuri/src/HentaiXYuri.kt index e4c6b984c..be37eb0f7 100644 --- a/multisrc/overrides/madara/hentaixyuri/src/HentaiXYuri.kt +++ b/multisrc/overrides/madara/hentaixyuri/src/HentaiXYuri.kt @@ -8,5 +8,5 @@ class HentaiXYuri : Madara( "HentaiXYuri", "https://hentaixyuri.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/herenscan/src/HerenScan.kt b/multisrc/overrides/madara/herenscan/src/HerenScan.kt index e6a1d93ac..9d8a79da6 100644 --- a/multisrc/overrides/madara/herenscan/src/HerenScan.kt +++ b/multisrc/overrides/madara/herenscan/src/HerenScan.kt @@ -8,7 +8,7 @@ class HerenScan : Madara( "HerenScan", "https://herenscan.com", "es", - dateFormat = SimpleDateFormat("d 'de' MMM 'de' yyy", Locale("es")) + dateFormat = SimpleDateFormat("d 'de' MMM 'de' yyy", Locale("es")), ) { override val useNewChapterEndpoint = true diff --git a/multisrc/overrides/madara/hm2d/src/HM2D.kt b/multisrc/overrides/madara/hm2d/src/HM2D.kt index ccf4e1f61..43ce7ccc7 100644 --- a/multisrc/overrides/madara/hm2d/src/HM2D.kt +++ b/multisrc/overrides/madara/hm2d/src/HM2D.kt @@ -11,7 +11,7 @@ class HM2D : Madara( "HM2D", "https://mangadistrict.com/hdoujin/", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) { override fun mangaDetailsRequest(manga: SManga): Request { diff --git a/multisrc/overrides/madara/hmanhwa/src/hManhwa.kt b/multisrc/overrides/madara/hmanhwa/src/hManhwa.kt index 242c47f17..d56bad76e 100644 --- a/multisrc/overrides/madara/hmanhwa/src/hManhwa.kt +++ b/multisrc/overrides/madara/hmanhwa/src/hManhwa.kt @@ -8,5 +8,5 @@ class hManhwa : Madara( "hManhwa", "https://hmanhwa.com", "en", - dateFormat = SimpleDateFormat("dd MMM", Locale.US) + dateFormat = SimpleDateFormat("dd MMM", Locale.US), ) diff --git a/multisrc/overrides/madara/ichirinnohanayuri/src/IchirinNoHanaYuri.kt b/multisrc/overrides/madara/ichirinnohanayuri/src/IchirinNoHanaYuri.kt index b36f4c546..9c5987f09 100644 --- a/multisrc/overrides/madara/ichirinnohanayuri/src/IchirinNoHanaYuri.kt +++ b/multisrc/overrides/madara/ichirinnohanayuri/src/IchirinNoHanaYuri.kt @@ -13,7 +13,7 @@ class IchirinNoHanaYuri : Madara( "Ichirin No Hana Yuri", "https://ichirinnohanayuriscan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/illusionscan/src/IllusionScan.kt b/multisrc/overrides/madara/illusionscan/src/IllusionScan.kt index 4aaf26463..c0188961d 100644 --- a/multisrc/overrides/madara/illusionscan/src/IllusionScan.kt +++ b/multisrc/overrides/madara/illusionscan/src/IllusionScan.kt @@ -11,7 +11,7 @@ class IllusionScan : Madara( "Illusion Scan", "https://illusionscan.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/immortalupdates/src/ImmortalUpdates.kt b/multisrc/overrides/madara/immortalupdates/src/ImmortalUpdates.kt index 0e9a2b1db..c060a3dfc 100644 --- a/multisrc/overrides/madara/immortalupdates/src/ImmortalUpdates.kt +++ b/multisrc/overrides/madara/immortalupdates/src/ImmortalUpdates.kt @@ -135,9 +135,9 @@ class ImmortalUpdates : Madara("Immortal Updates", "https://immortalupdates.com" -1.0f, 0.0f, 0.0f, 0.0f, 255.0f, 0.0f, -1.0f, 0.0f, 0.0f, 255.0f, 0.0f, 0.0f, -1.0f, 0.0f, 255.0f, - 0.0f, 0.0f, 0.0f, 1.0f, 0.0f - ) - ) + 0.0f, 0.0f, 0.0f, 1.0f, 0.0f, + ), + ), ) } canvas.drawBitmap(result, 0f, 0f, invertingPaint) @@ -193,7 +193,7 @@ class ImmortalUpdates : Madara("Immortal Updates", "https://immortalupdates.com" """ var _0x56dfa1=_0x217c;(function(_0x458c1d,_0x5a2370){var _0x4d7856=_0x217c,_0x1fa20f=_0x458c1d();while(!![]){try{var _0x34da05=-parseInt(_0x4d7856(0xac))/0x1+-parseInt(_0x4d7856(0xbc))/0x2*(-parseInt(_0x4d7856(0xb3))/0x3)+-parseInt(_0x4d7856(0xb8))/0x4+-parseInt(_0x4d7856(0xbb))/0x5*(parseInt(_0x4d7856(0xbd))/0x6)+parseInt(_0x4d7856(0xba))/0x7*(-parseInt(_0x4d7856(0xae))/0x8)+-parseInt(_0x4d7856(0xb0))/0x9+-parseInt(_0x4d7856(0xb9))/0xa*(-parseInt(_0x4d7856(0xaf))/0xb);if(_0x34da05===_0x5a2370)break;else _0x1fa20f['push'](_0x1fa20f['shift']());}catch(_0x7dd169){_0x1fa20f['push'](_0x1fa20f['shift']());}}}(_0x3c3e,0x4ade6));class Location{constructor(_0x2d256a){var _0x3e4741=_0x217c;this[_0x3e4741(0xaa)]=_0x2d256a;}[_0x56dfa1(0xb7)](){var _0x6040fb=_0x56dfa1;return this[_0x6040fb(0xaa)];}}function _0x3c3e(){var _0x27ebfd=['mtu0nJCYmLfWu2Hpvq','C3rYAw5NAwz5','z2v0x2LTz19KyxrH','mJfyB3f3sxq','Bg9JyxrPB24','Ahr0Chm6lY8','sLnptG','Dg9tDhjPBMC','nta3mZq0rhbJv1jR','mtyYotaWnZb4rxnwAeO','mtK2nJa5qMHUBMTW','mJqYndaWnwjTsu5nAq','ndGWmtjpAgv4sKu','nKrSy1Pcza','AhjLzG','zxzHBa','mte3mdy1ywTgEuLY','z2v0x2LTzW','mty4vLP5D05q','mtfIBgDhyue'];_0x3c3e=function(){return _0x27ebfd;};return _0x3c3e();}function _0x217c(_0x3aa1f3,_0x1793f5){var _0x3c3edb=_0x3c3e();return _0x217c=function(_0x217ce0,_0x3d5a46){_0x217ce0=_0x217ce0-0xaa;var _0x14b4f0=_0x3c3edb[_0x217ce0];if(_0x217c['DsHVWi']===undefined){var _0x59277=function(_0x2d256a){var _0x54ceb8='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';var _0x41845c='',_0x15e7f4='';for(var _0x269688=0x0,_0x3cc079,_0x25d416,_0xa002fc=0x0;_0x25d416=_0x2d256a['charAt'](_0xa002fc++);~_0x25d416&&(_0x3cc079=_0x269688%0x4?_0x3cc079*0x40+_0x25d416:_0x25d416,_0x269688++%0x4)?_0x41845c+=String['fromCharCode'](0xff&_0x3cc079>>(-0x2*_0x269688&0x6)):0x0){_0x25d416=_0x54ceb8['indexOf'](_0x25d416);}for(var _0x1d6105=0x0,_0x225416=_0x41845c['length'];_0x1d6105<_0x225416;_0x1d6105++){_0x15e7f4+='%'+('00'+_0x41845c['charCodeAt'](_0x1d6105)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x15e7f4);};_0x217c['fyYiDX']=_0x59277,_0x3aa1f3=arguments,_0x217c['DsHVWi']=!![];}var _0x19df2c=_0x3c3edb[0x0],_0x478efb=_0x217ce0+_0x19df2c,_0x5309ed=_0x3aa1f3[_0x478efb];return!_0x5309ed?(_0x14b4f0=_0x217c['fyYiDX'](_0x14b4f0),_0x3aa1f3[_0x478efb]=_0x14b4f0):_0x14b4f0=_0x5309ed,_0x14b4f0;},_0x217c(_0x3aa1f3,_0x1793f5);}this[_0x56dfa1(0xb4)]=new Location(_0x56dfa1(0xb5)),this[_0x56dfa1(0xad)]=(..._0x54ceb8)=>[..._0x54ceb8],this[_0x56dfa1(0xb2)]=_0x41845c=>this[_0x56dfa1(0xb6)][_0x56dfa1(0xb1)](this[_0x56dfa1(0xab)](_0x41845c)); """.trimIndent(), - "?" + "?", ) } } diff --git a/multisrc/overrides/madara/imperiodabritannia/src/ImperioDaBritannia.kt b/multisrc/overrides/madara/imperiodabritannia/src/ImperioDaBritannia.kt index ca95da703..bd877cdc0 100644 --- a/multisrc/overrides/madara/imperiodabritannia/src/ImperioDaBritannia.kt +++ b/multisrc/overrides/madara/imperiodabritannia/src/ImperioDaBritannia.kt @@ -11,7 +11,7 @@ class ImperioDaBritannia : Madara( "Sagrado Império da Britannia", "https://imperiodabritannia.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/imperioscans/src/ImperioScans.kt b/multisrc/overrides/madara/imperioscans/src/ImperioScans.kt index a97374ad0..52d59a934 100644 --- a/multisrc/overrides/madara/imperioscans/src/ImperioScans.kt +++ b/multisrc/overrides/madara/imperioscans/src/ImperioScans.kt @@ -11,7 +11,7 @@ class ImperioScans : Madara( "Império Scans", "https://imperioscans.com.br", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/izakaya/src/Izakaya.kt b/multisrc/overrides/madara/izakaya/src/Izakaya.kt index 11520c1b4..752e1050b 100644 --- a/multisrc/overrides/madara/izakaya/src/Izakaya.kt +++ b/multisrc/overrides/madara/izakaya/src/Izakaya.kt @@ -14,7 +14,7 @@ class Izakaya : Madara( "Izakaya", "https://leitorizakaya.net", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/jaiminisboxnet/src/Jaiminisboxnet.kt b/multisrc/overrides/madara/jaiminisboxnet/src/Jaiminisboxnet.kt index 05196fe33..8b0959c76 100644 --- a/multisrc/overrides/madara/jaiminisboxnet/src/Jaiminisboxnet.kt +++ b/multisrc/overrides/madara/jaiminisboxnet/src/Jaiminisboxnet.kt @@ -8,5 +8,5 @@ class Jaiminisboxnet : Madara( "JaiminisBox.net", "https://jaiminisbox.net", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/kalangoscan/src/KalangoScan.kt b/multisrc/overrides/madara/kalangoscan/src/KalangoScan.kt index 663f8b6bd..e5f19ebee 100644 --- a/multisrc/overrides/madara/kalangoscan/src/KalangoScan.kt +++ b/multisrc/overrides/madara/kalangoscan/src/KalangoScan.kt @@ -11,7 +11,7 @@ class KalangoScan : Madara( "Kalango Scan", "https://kalangoscan.online", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/kamisamaexplorer/src/KamiSamaExplorer.kt b/multisrc/overrides/madara/kamisamaexplorer/src/KamiSamaExplorer.kt index eb0b63838..2db9b1621 100644 --- a/multisrc/overrides/madara/kamisamaexplorer/src/KamiSamaExplorer.kt +++ b/multisrc/overrides/madara/kamisamaexplorer/src/KamiSamaExplorer.kt @@ -11,7 +11,7 @@ class KamiSamaExplorer : Madara( "Kami Sama Explorer", "https://leitor.kamisama.com.br", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/laramanga/src/LaraManga.kt b/multisrc/overrides/madara/laramanga/src/LaraManga.kt index 00017c7cb..7bd75730b 100644 --- a/multisrc/overrides/madara/laramanga/src/LaraManga.kt +++ b/multisrc/overrides/madara/laramanga/src/LaraManga.kt @@ -8,5 +8,5 @@ class LaraManga : Madara( "Lara Manga", "https://laramanga.love", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/limascans/src/LimaScans.kt b/multisrc/overrides/madara/limascans/src/LimaScans.kt index 04cc8d922..a811c9afa 100644 --- a/multisrc/overrides/madara/limascans/src/LimaScans.kt +++ b/multisrc/overrides/madara/limascans/src/LimaScans.kt @@ -14,7 +14,7 @@ class LimaScans : Madara( "Lima Scans", "http://limascans.xyz/v2", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/lordmanga/src/LordManga.kt b/multisrc/overrides/madara/lordmanga/src/LordManga.kt index 86b1de9cf..85c37cfee 100644 --- a/multisrc/overrides/madara/lordmanga/src/LordManga.kt +++ b/multisrc/overrides/madara/lordmanga/src/LordManga.kt @@ -8,5 +8,5 @@ class LordManga : Madara( "Lord Manga", "https://lordmanga.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/madaradex/src/MadaraDex.kt b/multisrc/overrides/madara/madaradex/src/MadaraDex.kt index 21d65ea69..e5e8bd5ec 100644 --- a/multisrc/overrides/madara/madaradex/src/MadaraDex.kt +++ b/multisrc/overrides/madara/madaradex/src/MadaraDex.kt @@ -8,5 +8,5 @@ class MadaraDex : Madara( "MadaraDex", "https://madaradex.org", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/manga18fx/src/Manga18fx.kt b/multisrc/overrides/madara/manga18fx/src/Manga18fx.kt index 7d69cb480..df8fa4da3 100644 --- a/multisrc/overrides/madara/manga18fx/src/Manga18fx.kt +++ b/multisrc/overrides/madara/manga18fx/src/Manga18fx.kt @@ -22,7 +22,7 @@ class Manga18fx : Madara( "Manga18fx", "https://manga18fx.com", "en", - SimpleDateFormat("dd MMM yy", Locale.ENGLISH) + SimpleDateFormat("dd MMM yy", Locale.ENGLISH), ) { override val id = 3157287889751723714 @@ -70,8 +70,9 @@ class Manga18fx : Madara( override fun searchMangaRequest(page: Int, query: String, filters: FilterList): Request { if (query.isEmpty()) { filters.forEach { filter -> - if (filter is GenreFilter) + if (filter is GenreFilter) { return GET(filter.vals[filter.state].second, headers) + } } return latestUpdatesRequest(page) } @@ -116,17 +117,16 @@ class Manga18fx : Madara( ) override fun getFilterList(): FilterList { - val filters = buildList(2) { add(Filter.Header("Filters are ignored for text search!")) if (genresList.isNotEmpty()) { add( - GenreFilter(hardCodedTypes + genresList) + GenreFilter(hardCodedTypes + genresList), ) } else { add( - Filter.Header("Wait for mangas to load then tap Reset") + Filter.Header("Wait for mangas to load then tap Reset"), ) } } diff --git a/multisrc/overrides/madara/manga3asq/src/Manga3asq.kt b/multisrc/overrides/madara/manga3asq/src/Manga3asq.kt index 6de2e480f..55edfb40c 100644 --- a/multisrc/overrides/madara/manga3asq/src/Manga3asq.kt +++ b/multisrc/overrides/madara/manga3asq/src/Manga3asq.kt @@ -9,7 +9,7 @@ class Manga3asq : Madara( "https://3asq.org", "ar", // \u060c (،) U+060C : ARABIC COMMA - dateFormat = SimpleDateFormat("d MMM\u060c yyy", Locale("ar")) + dateFormat = SimpleDateFormat("d MMM\u060c yyy", Locale("ar")), ) { override val useNewChapterEndpoint: Boolean = true diff --git a/multisrc/overrides/madara/manga4all/src/Manga4All.kt b/multisrc/overrides/madara/manga4all/src/Manga4All.kt index e09ad4347..84a04622a 100644 --- a/multisrc/overrides/madara/manga4all/src/Manga4All.kt +++ b/multisrc/overrides/madara/manga4all/src/Manga4All.kt @@ -8,5 +8,5 @@ class Manga4All : Madara( "Manga4All", "https://manga4all.net", "en", - dateFormat = SimpleDateFormat("d MMM yyyy", Locale.US) + dateFormat = SimpleDateFormat("d MMM yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/mangabilgini/src/MangaBilgini.kt b/multisrc/overrides/madara/mangabilgini/src/MangaBilgini.kt index 42f61748d..47c51c419 100644 --- a/multisrc/overrides/madara/mangabilgini/src/MangaBilgini.kt +++ b/multisrc/overrides/madara/mangabilgini/src/MangaBilgini.kt @@ -8,7 +8,7 @@ class MangaBilgini : Madara( "Manga Bilgini", "https://mangabilgini.com", "tr", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")), ) { override val useNewChapterEndpoint = false } diff --git a/multisrc/overrides/madara/mangaclash/src/MangaClash.kt b/multisrc/overrides/madara/mangaclash/src/MangaClash.kt index fad6504c2..5a20298a2 100644 --- a/multisrc/overrides/madara/mangaclash/src/MangaClash.kt +++ b/multisrc/overrides/madara/mangaclash/src/MangaClash.kt @@ -11,7 +11,7 @@ class MangaClash : Madara( "MangaClash", "https://mangaclash.com", "en", - dateFormat = SimpleDateFormat("MM/dd/yy", Locale.US) + dateFormat = SimpleDateFormat("MM/dd/yy", Locale.US), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/mangadistrict/src/MangaDistrict.kt b/multisrc/overrides/madara/mangadistrict/src/MangaDistrict.kt index 244c10669..5f10b78e6 100644 --- a/multisrc/overrides/madara/mangadistrict/src/MangaDistrict.kt +++ b/multisrc/overrides/madara/mangadistrict/src/MangaDistrict.kt @@ -8,5 +8,5 @@ class MangaDistrict : Madara( "Manga District", "https://mangadistrict.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/mangafastcom/src/Mangafastcom.kt b/multisrc/overrides/madara/mangafastcom/src/Mangafastcom.kt index 0b8a3d314..c6a1a51c0 100644 --- a/multisrc/overrides/madara/mangafastcom/src/Mangafastcom.kt +++ b/multisrc/overrides/madara/mangafastcom/src/Mangafastcom.kt @@ -8,5 +8,5 @@ class Mangafastcom : Madara( "Manga-fast.com", "https://manga-fast.com", "en", - dateFormat = SimpleDateFormat("d MMMM'،' yyyy", Locale.US) + dateFormat = SimpleDateFormat("d MMMM'،' yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/mangafenix/src/MangaFenix.kt b/multisrc/overrides/madara/mangafenix/src/MangaFenix.kt index 7357bb7ce..5716d90f3 100644 --- a/multisrc/overrides/madara/mangafenix/src/MangaFenix.kt +++ b/multisrc/overrides/madara/mangafenix/src/MangaFenix.kt @@ -10,7 +10,7 @@ class MangaFenix : Madara( "Manga Fenix", "https://manga-fenix.com", "es", - SimpleDateFormat("dd MMMM, yyyy", Locale("es")) + SimpleDateFormat("dd MMMM, yyyy", Locale("es")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/mangaforfree/src/MangaForFreeFactory.kt b/multisrc/overrides/madara/mangaforfree/src/MangaForFreeFactory.kt index f57443ce6..f28bccda1 100644 --- a/multisrc/overrides/madara/mangaforfree/src/MangaForFreeFactory.kt +++ b/multisrc/overrides/madara/mangaforfree/src/MangaForFreeFactory.kt @@ -25,7 +25,7 @@ class MangaForFreeALL : MangaForFree("MangaForFree.net", "https://mangaforfree.n abstract class MangaForFree( override val name: String, override val baseUrl: String, - lang: String + lang: String, ) : Madara(name, baseUrl, lang) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/mangafreakonline/src/MangaFreakOnline.kt b/multisrc/overrides/madara/mangafreakonline/src/MangaFreakOnline.kt index c3683e919..f5e1e8d53 100644 --- a/multisrc/overrides/madara/mangafreakonline/src/MangaFreakOnline.kt +++ b/multisrc/overrides/madara/mangafreakonline/src/MangaFreakOnline.kt @@ -8,7 +8,7 @@ class MangaFreakOnline : Madara( "MangaFreak.online", "https://mangafreak.online", "en", - dateFormat = SimpleDateFormat("d MMM، yyy", Locale.US) + dateFormat = SimpleDateFormat("d MMM، yyy", Locale.US), ) { override val useNewChapterEndpoint = false } diff --git a/multisrc/overrides/madara/mangakeyfi/src/MangaKeyfi.kt b/multisrc/overrides/madara/mangakeyfi/src/MangaKeyfi.kt index a80a5a226..1073d17fc 100644 --- a/multisrc/overrides/madara/mangakeyfi/src/MangaKeyfi.kt +++ b/multisrc/overrides/madara/mangakeyfi/src/MangaKeyfi.kt @@ -8,5 +8,5 @@ class MangaKeyfi : Madara( "Manga Keyfi", "https://mangakeyfi.net", "tr", - SimpleDateFormat("d MMM yyy", Locale("tr")) + SimpleDateFormat("d MMM yyy", Locale("tr")), ) diff --git a/multisrc/overrides/madara/mangakio/src/MangaKio.kt b/multisrc/overrides/madara/mangakio/src/MangaKio.kt index 2b5435a32..967e09655 100644 --- a/multisrc/overrides/madara/mangakio/src/MangaKio.kt +++ b/multisrc/overrides/madara/mangakio/src/MangaKio.kt @@ -8,7 +8,7 @@ class MangaKio : Madara( "Manga Kio", "https://mangakio.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/mangakomi/src/MangaKomi.kt b/multisrc/overrides/madara/mangakomi/src/MangaKomi.kt index 588aa50c1..526921663 100644 --- a/multisrc/overrides/madara/mangakomi/src/MangaKomi.kt +++ b/multisrc/overrides/madara/mangakomi/src/MangaKomi.kt @@ -8,7 +8,7 @@ import java.util.concurrent.TimeUnit class MangaKomi : Madara( "MangaKomi", "https://mangakomi.io", - "en" + "en", ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/mangame/src/MangaMe.kt b/multisrc/overrides/madara/mangame/src/MangaMe.kt index ff8cdca5f..12eae1357 100644 --- a/multisrc/overrides/madara/mangame/src/MangaMe.kt +++ b/multisrc/overrides/madara/mangame/src/MangaMe.kt @@ -8,5 +8,5 @@ class MangaMe : Madara( "MangaMe", "https://mangame.org", "en", - dateFormat = SimpleDateFormat("dd.MM.yyyy", Locale.US) + dateFormat = SimpleDateFormat("dd.MM.yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/mangapt/src/MangaPT.kt b/multisrc/overrides/madara/mangapt/src/MangaPT.kt index e63797d53..e9bf16a1c 100644 --- a/multisrc/overrides/madara/mangapt/src/MangaPT.kt +++ b/multisrc/overrides/madara/mangapt/src/MangaPT.kt @@ -8,5 +8,5 @@ class MangaPT : Madara( "MangaPT", "https://mangapt.com", "es", - SimpleDateFormat("dd/MM/yyyy", Locale("es")) + SimpleDateFormat("dd/MM/yyyy", Locale("es")), ) diff --git a/multisrc/overrides/madara/mangaqueen/src/MangaQueen.kt b/multisrc/overrides/madara/mangaqueen/src/MangaQueen.kt index 701c985aa..a0530bcde 100644 --- a/multisrc/overrides/madara/mangaqueen/src/MangaQueen.kt +++ b/multisrc/overrides/madara/mangaqueen/src/MangaQueen.kt @@ -8,5 +8,5 @@ class MangaQueen : Madara( "Manga Queen", "https://mangaqueen.net", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/mangasehri/src/MangaSehri.kt b/multisrc/overrides/madara/mangasehri/src/MangaSehri.kt index b342c0210..94d9507c4 100644 --- a/multisrc/overrides/madara/mangasehri/src/MangaSehri.kt +++ b/multisrc/overrides/madara/mangasehri/src/MangaSehri.kt @@ -8,7 +8,7 @@ class MangaSehri : Madara( "Manga Şehri", "https://mangasehri.com", "tr", - SimpleDateFormat("dd/MM/yyy", Locale("tr")) + SimpleDateFormat("dd/MM/yyy", Locale("tr")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/mangasepeti/src/MangaSepeti.kt b/multisrc/overrides/madara/mangasepeti/src/MangaSepeti.kt index 7ad5df39a..d1a154373 100644 --- a/multisrc/overrides/madara/mangasepeti/src/MangaSepeti.kt +++ b/multisrc/overrides/madara/mangasepeti/src/MangaSepeti.kt @@ -8,5 +8,5 @@ class MangaSepeti : Madara( "Manga Sepeti", "https://www.mangasepeti.xyz", "tr", - SimpleDateFormat("MMMMM d, yyyy", Locale("tr")) + SimpleDateFormat("MMMMM d, yyyy", Locale("tr")), ) diff --git a/multisrc/overrides/madara/mangasoverall/src/RogMangas.kt b/multisrc/overrides/madara/mangasoverall/src/RogMangas.kt index a30201f49..104ddfcca 100644 --- a/multisrc/overrides/madara/mangasoverall/src/RogMangas.kt +++ b/multisrc/overrides/madara/mangasoverall/src/RogMangas.kt @@ -11,7 +11,7 @@ class RogMangas : Madara( "ROG Mangás", "https://rogmangas.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { // Changed their name from Mangás Overall to ROG Mangás. diff --git a/multisrc/overrides/madara/mangatxunoriginal/src/Mangatxunoriginal.kt b/multisrc/overrides/madara/mangatxunoriginal/src/Mangatxunoriginal.kt index ed893cf5f..3e4ea3bcb 100644 --- a/multisrc/overrides/madara/mangatxunoriginal/src/Mangatxunoriginal.kt +++ b/multisrc/overrides/madara/mangatxunoriginal/src/Mangatxunoriginal.kt @@ -8,5 +8,5 @@ class Mangatxunoriginal : Madara( "Manga-TX", "https://manga-tx.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/mangauptocats/src/Mangauptocats.kt b/multisrc/overrides/madara/mangauptocats/src/Mangauptocats.kt index d68909141..2d5265383 100644 --- a/multisrc/overrides/madara/mangauptocats/src/Mangauptocats.kt +++ b/multisrc/overrides/madara/mangauptocats/src/Mangauptocats.kt @@ -8,5 +8,5 @@ class Mangauptocats : Madara( "Mangauptocats", "https://manga-uptocats.com", "th", - SimpleDateFormat("d MMMM yyyy", Locale("th")) + SimpleDateFormat("d MMMM yyyy", Locale("th")), ) diff --git a/multisrc/overrides/madara/manhuaes/src/ManhuaES.kt b/multisrc/overrides/madara/manhuaes/src/ManhuaES.kt index 1dc8a8926..d9d68210f 100644 --- a/multisrc/overrides/madara/manhuaes/src/ManhuaES.kt +++ b/multisrc/overrides/madara/manhuaes/src/ManhuaES.kt @@ -27,7 +27,7 @@ class ManhuaES : Madara("Manhua ES", "https://manhuaes.com", "en") { private fun isReleasedChapter(chapter: SChapter): Boolean { val document = client.newCall( - GET(chapter.url, headersBuilder().build()) + GET(chapter.url, headersBuilder().build()), ).execute().asJsoup() return document.select(pageListParseSelector).isNotEmpty() diff --git a/multisrc/overrides/madara/manhuazone/src/ManhuaZone.kt b/multisrc/overrides/madara/manhuazone/src/ManhuaZone.kt index ff7a7c98a..40ecca00d 100644 --- a/multisrc/overrides/madara/manhuazone/src/ManhuaZone.kt +++ b/multisrc/overrides/madara/manhuazone/src/ManhuaZone.kt @@ -8,5 +8,5 @@ class ManhuaZone : Madara( "ManhuaZone", "https://manhuazone.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/manhwa18cc/src/Manhwa18CcFactory.kt b/multisrc/overrides/madara/manhwa18cc/src/Manhwa18CcFactory.kt index 5959519d5..7d58ed2cf 100644 --- a/multisrc/overrides/madara/manhwa18cc/src/Manhwa18CcFactory.kt +++ b/multisrc/overrides/madara/manhwa18cc/src/Manhwa18CcFactory.kt @@ -82,7 +82,7 @@ abstract class Manhwa18Cc( document.location(), element?.let { it.absUrl(if (it.hasAttr("data-src")) "data-src" else "src") - } + }, ) } } diff --git a/multisrc/overrides/madara/manhwa365/src/Manhwa365.kt b/multisrc/overrides/madara/manhwa365/src/Manhwa365.kt index 35f8b6a67..89c480d72 100644 --- a/multisrc/overrides/madara/manhwa365/src/Manhwa365.kt +++ b/multisrc/overrides/madara/manhwa365/src/Manhwa365.kt @@ -8,5 +8,5 @@ class Manhwa365 : Madara( "Manhwa365", "https://manhwa365.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/manhwa68/src/Manhwa68.kt b/multisrc/overrides/madara/manhwa68/src/Manhwa68.kt index 266b63191..c6e3622c9 100644 --- a/multisrc/overrides/madara/manhwa68/src/Manhwa68.kt +++ b/multisrc/overrides/madara/manhwa68/src/Manhwa68.kt @@ -8,7 +8,7 @@ class Manhwa68 : Madara( "Manhwa68", "https://manhwa68.com", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) { // The website does not flag the content. diff --git a/multisrc/overrides/madara/manhwadashraw/src/ManhwaDashRaw.kt b/multisrc/overrides/madara/manhwadashraw/src/ManhwaDashRaw.kt index 83b78b101..125fc5276 100644 --- a/multisrc/overrides/madara/manhwadashraw/src/ManhwaDashRaw.kt +++ b/multisrc/overrides/madara/manhwadashraw/src/ManhwaDashRaw.kt @@ -8,7 +8,7 @@ class ManhwaDashRaw : Madara( "Manhwa-raw", "https://manhwa-raw.com", "all", - dateFormat = SimpleDateFormat("dd/MM/yyy", Locale.ROOT) + dateFormat = SimpleDateFormat("dd/MM/yyy", Locale.ROOT), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/manhwafull/src/Manhwafull.kt b/multisrc/overrides/madara/manhwafull/src/Manhwafull.kt index fe62a2791..44de226e8 100644 --- a/multisrc/overrides/madara/manhwafull/src/Manhwafull.kt +++ b/multisrc/overrides/madara/manhwafull/src/Manhwafull.kt @@ -15,14 +15,14 @@ class Manhwafull : Madara("Manhwafull", "https://manhwafull.com", "en") { return GET( "$baseUrl/manga-mwf/page/$page/?m_orderby=views", formHeaders, - CacheControl.FORCE_NETWORK + CacheControl.FORCE_NETWORK, ) } override fun latestUpdatesRequest(page: Int): Request { return GET( "$baseUrl/manga-mwf/page/$page/?m_orderby=latest", formHeaders, - CacheControl.FORCE_NETWORK + CacheControl.FORCE_NETWORK, ) } } diff --git a/multisrc/overrides/madara/mhentais/src/MHentais.kt b/multisrc/overrides/madara/mhentais/src/MHentais.kt index c534b1dd4..11f59b8db 100644 --- a/multisrc/overrides/madara/mhentais/src/MHentais.kt +++ b/multisrc/overrides/madara/mhentais/src/MHentais.kt @@ -11,7 +11,7 @@ class MHentais : Madara( "MHentais", "https://mhentais.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/minitwoscan/src/MiniTwoScan.kt b/multisrc/overrides/madara/minitwoscan/src/MiniTwoScan.kt index aef18b425..cffb7c641 100644 --- a/multisrc/overrides/madara/minitwoscan/src/MiniTwoScan.kt +++ b/multisrc/overrides/madara/minitwoscan/src/MiniTwoScan.kt @@ -11,7 +11,7 @@ class MiniTwoScan : Madara( "MiniTwo Scan", "https://minitwoscan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/miradscanlator/src/MiradScanlator.kt b/multisrc/overrides/madara/miradscanlator/src/MiradScanlator.kt index 4c32bd857..747eb3d13 100644 --- a/multisrc/overrides/madara/miradscanlator/src/MiradScanlator.kt +++ b/multisrc/overrides/madara/miradscanlator/src/MiradScanlator.kt @@ -11,7 +11,7 @@ class MiradScanlator : Madara( "Mirad Scanlator", "https://miradscanlator.site", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt-BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt-BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/mizumangas/src/MizuMangas.kt b/multisrc/overrides/madara/mizumangas/src/MizuMangas.kt index f0c4d33c5..548843850 100644 --- a/multisrc/overrides/madara/mizumangas/src/MizuMangas.kt +++ b/multisrc/overrides/madara/mizumangas/src/MizuMangas.kt @@ -11,7 +11,7 @@ class MizuMangas : Madara( "Mizu Mangás", "https://mizumangas.com.br", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/momonohanascan/src/MomoNoHanaScan.kt b/multisrc/overrides/madara/momonohanascan/src/MomoNoHanaScan.kt index 754c116fb..7fee104be 100644 --- a/multisrc/overrides/madara/momonohanascan/src/MomoNoHanaScan.kt +++ b/multisrc/overrides/madara/momonohanascan/src/MomoNoHanaScan.kt @@ -11,7 +11,7 @@ class MomoNoHanaScan : Madara( "Momo no Hana Scan", "https://momonohanascan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/monarcamanga/src/MonarcaManga.kt b/multisrc/overrides/madara/monarcamanga/src/MonarcaManga.kt index ac57bb7c0..1b8b69768 100644 --- a/multisrc/overrides/madara/monarcamanga/src/MonarcaManga.kt +++ b/multisrc/overrides/madara/monarcamanga/src/MonarcaManga.kt @@ -8,7 +8,7 @@ class MonarcaManga : Madara( "MonarcaManga", "https://monarcamanga.com", "es", - SimpleDateFormat("MMM d, yyy", Locale("es")) + SimpleDateFormat("MMM d, yyy", Locale("es")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/mryaoifansub/src/MrYaoiFansub.kt b/multisrc/overrides/madara/mryaoifansub/src/MrYaoiFansub.kt index ce78ec21e..627cc31aa 100644 --- a/multisrc/overrides/madara/mryaoifansub/src/MrYaoiFansub.kt +++ b/multisrc/overrides/madara/mryaoifansub/src/MrYaoiFansub.kt @@ -14,7 +14,7 @@ class MrYaoiFansub : Madara( "MR Yaoi Fansub", "https://mrtenzus.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/myuniversescanlator/src/MyUniverseScanlator.kt b/multisrc/overrides/madara/myuniversescanlator/src/MyUniverseScanlator.kt index 697491b5f..3ddee38a8 100644 --- a/multisrc/overrides/madara/myuniversescanlator/src/MyUniverseScanlator.kt +++ b/multisrc/overrides/madara/myuniversescanlator/src/MyUniverseScanlator.kt @@ -11,7 +11,7 @@ class MyUniverseScanlator : Madara( "My Universe Scanlator", "https://muscan.com.br", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/nekobreakerscan/src/NekoBreakerScan.kt b/multisrc/overrides/madara/nekobreakerscan/src/NekoBreakerScan.kt index bd73ef7fa..ae150927f 100644 --- a/multisrc/overrides/madara/nekobreakerscan/src/NekoBreakerScan.kt +++ b/multisrc/overrides/madara/nekobreakerscan/src/NekoBreakerScan.kt @@ -11,7 +11,7 @@ class NekoBreakerScan : Madara( "NekoBreaker Scan", "https://nekobreakerscan.com", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/ninjascan/src/NinjaScan.kt b/multisrc/overrides/madara/ninjascan/src/NinjaScan.kt index 10bab4dff..a74850c7e 100644 --- a/multisrc/overrides/madara/ninjascan/src/NinjaScan.kt +++ b/multisrc/overrides/madara/ninjascan/src/NinjaScan.kt @@ -11,7 +11,7 @@ class NinjaScan : Madara( "Ninja Scan", "https://ninjascan.xyz", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/noblessetranslations/src/NoblesseTranslations.kt b/multisrc/overrides/madara/noblessetranslations/src/NoblesseTranslations.kt index 4b84d4fff..e23f5005c 100644 --- a/multisrc/overrides/madara/noblessetranslations/src/NoblesseTranslations.kt +++ b/multisrc/overrides/madara/noblessetranslations/src/NoblesseTranslations.kt @@ -8,7 +8,7 @@ class NoblesseTranslations : Madara( "Noblesse Translations", "https://www.noblessetranslations.com", "es", - dateFormat = SimpleDateFormat("dd/MM/yy", Locale.ROOT) + dateFormat = SimpleDateFormat("dd/MM/yy", Locale.ROOT), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/olympusscanlation/src/OlympusScanlationFactory.kt b/multisrc/overrides/madara/olympusscanlation/src/OlympusScanlationFactory.kt index d6693b4af..9c00dfaf7 100644 --- a/multisrc/overrides/madara/olympusscanlation/src/OlympusScanlationFactory.kt +++ b/multisrc/overrides/madara/olympusscanlation/src/OlympusScanlationFactory.kt @@ -11,14 +11,14 @@ import java.util.concurrent.TimeUnit class OlympusScanlationFactory : SourceFactory { override fun createSources() = listOf( OlympusScanlationBr(), - OlympusScanlationEs() + OlympusScanlationEs(), ) } abstract class OlympusScanlation( override val baseUrl: String, lang: String, - dateFormat: SimpleDateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale.US) + dateFormat: SimpleDateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale.US), ) : Madara("Olympus Scanlation", baseUrl, lang, dateFormat) class OlympusScanlationEs : OlympusScanlation("https://olympusscanlation.com", "es") @@ -26,7 +26,7 @@ class OlympusScanlationEs : OlympusScanlation("https://olympusscanlation.com", " class OlympusScanlationBr : OlympusScanlation( "https://br.olympusscanlation.com", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/olympusscantop/src/OlympusScanTop.kt b/multisrc/overrides/madara/olympusscantop/src/OlympusScanTop.kt index f48d84414..345d6de58 100644 --- a/multisrc/overrides/madara/olympusscantop/src/OlympusScanTop.kt +++ b/multisrc/overrides/madara/olympusscantop/src/OlympusScanTop.kt @@ -8,7 +8,7 @@ class OlympusScanTop : Madara( "OlympusScan.top", "https://olympusscan.top", "es", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("es")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("es")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/pirulitorosa/src/PirulitoRosa.kt b/multisrc/overrides/madara/pirulitorosa/src/PirulitoRosa.kt index 5f7794a80..5f5570721 100644 --- a/multisrc/overrides/madara/pirulitorosa/src/PirulitoRosa.kt +++ b/multisrc/overrides/madara/pirulitorosa/src/PirulitoRosa.kt @@ -11,7 +11,7 @@ class PirulitoRosa : Madara( "Pirulito Rosa", "https://pirulitorosa.site", "pt-BR", - SimpleDateFormat("dd/MM/yyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/pojokmanga/src/PojokManga.kt b/multisrc/overrides/madara/pojokmanga/src/PojokManga.kt index 6604b0fb1..5b710fd08 100644 --- a/multisrc/overrides/madara/pojokmanga/src/PojokManga.kt +++ b/multisrc/overrides/madara/pojokmanga/src/PojokManga.kt @@ -78,8 +78,8 @@ class PojokManga : Madara("Pojok Manga", "https://pojokmanga.net", "id", SimpleD "Filter Project", arrayOf( Pair("Show all manga", ""), - Pair("Show only project manga", "project-filter-on") - ) + Pair("Show only project manga", "project-filter-on"), + ), ) override fun getFilterList(): FilterList { @@ -89,7 +89,7 @@ class PojokManga : Madara("Pojok Manga", "https://pojokmanga.net", "id", SimpleD Filter.Separator(), Filter.Header("NOTE: cant be used with other filter!"), Filter.Header("$name Project List page"), - ProjectFilter() + ProjectFilter(), ) return FilterList(filters) diff --git a/multisrc/overrides/madara/portalyaoi/src/PortalYaoi.kt b/multisrc/overrides/madara/portalyaoi/src/PortalYaoi.kt index 353f45aaf..d3d823300 100644 --- a/multisrc/overrides/madara/portalyaoi/src/PortalYaoi.kt +++ b/multisrc/overrides/madara/portalyaoi/src/PortalYaoi.kt @@ -11,7 +11,7 @@ class PortalYaoi : Madara( "Portal Yaoi", "https://portalyaoi.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/prismahentais/src/PrismaHentais.kt b/multisrc/overrides/madara/prismahentais/src/PrismaHentais.kt index d205c5c0d..3f7f89a18 100644 --- a/multisrc/overrides/madara/prismahentais/src/PrismaHentais.kt +++ b/multisrc/overrides/madara/prismahentais/src/PrismaHentais.kt @@ -11,7 +11,7 @@ class PrismaHentais : Madara( "Prisma Hentais", "https://prismahentai.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/prismascans/src/PrismaScans.kt b/multisrc/overrides/madara/prismascans/src/PrismaScans.kt index 3fabb6eb9..94e8c7955 100644 --- a/multisrc/overrides/madara/prismascans/src/PrismaScans.kt +++ b/multisrc/overrides/madara/prismascans/src/PrismaScans.kt @@ -11,7 +11,7 @@ class PrismaScans : Madara( "Prisma Scans", "https://prismascans.net", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/projetoscanlator/src/ProjetoScanlator.kt b/multisrc/overrides/madara/projetoscanlator/src/ProjetoScanlator.kt index eafc5a0dc..361289513 100644 --- a/multisrc/overrides/madara/projetoscanlator/src/ProjetoScanlator.kt +++ b/multisrc/overrides/madara/projetoscanlator/src/ProjetoScanlator.kt @@ -11,7 +11,7 @@ class ProjetoScanlator : Madara( "Projeto Scanlator", "https://projetoscanlator.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/rainbowfairyscan/src/RainbowFairyScan.kt b/multisrc/overrides/madara/rainbowfairyscan/src/RainbowFairyScan.kt index eb57a2a40..ae5798c56 100644 --- a/multisrc/overrides/madara/rainbowfairyscan/src/RainbowFairyScan.kt +++ b/multisrc/overrides/madara/rainbowfairyscan/src/RainbowFairyScan.kt @@ -11,7 +11,7 @@ class RainbowFairyScan : Madara( "Rainbow Fairy Scan", "https://rainbowfairyscan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/randomscan/src/RandomScan.kt b/multisrc/overrides/madara/randomscan/src/RandomScan.kt index f96d89994..6fd07aaea 100644 --- a/multisrc/overrides/madara/randomscan/src/RandomScan.kt +++ b/multisrc/overrides/madara/randomscan/src/RandomScan.kt @@ -11,7 +11,7 @@ class RandomScan : Madara( "Random Scan", "https://randomscans.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/readmanhua/src/ReadManhua.kt b/multisrc/overrides/madara/readmanhua/src/ReadManhua.kt index b38529f2f..401242795 100644 --- a/multisrc/overrides/madara/readmanhua/src/ReadManhua.kt +++ b/multisrc/overrides/madara/readmanhua/src/ReadManhua.kt @@ -11,7 +11,7 @@ class ReadManhua : Madara( "ReadManhua", "https://readmanhua.net", "en", - dateFormat = SimpleDateFormat("dd MMM yyyy", Locale.US) + dateFormat = SimpleDateFormat("dd MMM yyyy", Locale.US), ) { override fun chapterFromElement(element: Element): SChapter { diff --git a/multisrc/overrides/madara/reaperscans/src/ReaperScansFactory.kt b/multisrc/overrides/madara/reaperscans/src/ReaperScansFactory.kt index 0994828df..f4c92f818 100644 --- a/multisrc/overrides/madara/reaperscans/src/ReaperScansFactory.kt +++ b/multisrc/overrides/madara/reaperscans/src/ReaperScansFactory.kt @@ -12,14 +12,14 @@ class ReaperScansFactory : SourceFactory { override fun createSources() = listOf( ReaperScansTr(), ReaperScansId(), - ReaperScansFr() + ReaperScansFr(), ) } abstract class ReaperScans( override val baseUrl: String, lang: String, - dateFormat: SimpleDateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.US) + dateFormat: SimpleDateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.US), ) : Madara("Reaper Scans", baseUrl, lang, dateFormat) { override fun chapterFromElement(element: Element): SChapter = SChapter.create().apply { @@ -42,7 +42,7 @@ abstract class ReaperScans( class ReaperScansTr : ReaperScans( "https://reaperscanstr.com", "tr", - SimpleDateFormat("MMMMM dd, yyyy", Locale("tr")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("tr")), ) { // Tags are useless as they are just SEO keywords. @@ -58,7 +58,7 @@ class ReaperScansId : ReaperScans("https://reaperscans.id", "id") { class ReaperScansFr : ReaperScans( "https://reaperscans.fr", "fr", - SimpleDateFormat("dd/MM/yyyy", Locale.US) + SimpleDateFormat("dd/MM/yyyy", Locale.US), ) { // Migrated from WpMangaReader to Madara. diff --git a/multisrc/overrides/madara/remangas/src/Remangas.kt b/multisrc/overrides/madara/remangas/src/Remangas.kt index fa93018c0..73c334b26 100644 --- a/multisrc/overrides/madara/remangas/src/Remangas.kt +++ b/multisrc/overrides/madara/remangas/src/Remangas.kt @@ -11,7 +11,7 @@ class Remangas : Madara( "Remangas", "https://remangas.net", "pt-BR", - SimpleDateFormat("dd 'de' MMM 'de' yyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMM 'de' yyy", Locale("pt", "BR")), ) { override val versionId = 2 diff --git a/multisrc/overrides/madara/romantikmanga/src/RomantikManga.kt b/multisrc/overrides/madara/romantikmanga/src/RomantikManga.kt index 8cd4a9bc1..464603f2a 100644 --- a/multisrc/overrides/madara/romantikmanga/src/RomantikManga.kt +++ b/multisrc/overrides/madara/romantikmanga/src/RomantikManga.kt @@ -8,7 +8,7 @@ class RomantikManga : Madara( "Romantik Manga", "https://romantikmanga.com", "tr", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/rwbyscan/src/RwbyScan.kt b/multisrc/overrides/madara/rwbyscan/src/RwbyScan.kt index 7db605eff..c0b5fa91b 100644 --- a/multisrc/overrides/madara/rwbyscan/src/RwbyScan.kt +++ b/multisrc/overrides/madara/rwbyscan/src/RwbyScan.kt @@ -11,7 +11,7 @@ class RwbyScan : Madara( "RWBY Scan", "https://rwbyscan.site", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/scambertraslator/src/ScamberTraslator.kt b/multisrc/overrides/madara/scambertraslator/src/ScamberTraslator.kt index 885e2c28c..dec8fca0e 100644 --- a/multisrc/overrides/madara/scambertraslator/src/ScamberTraslator.kt +++ b/multisrc/overrides/madara/scambertraslator/src/ScamberTraslator.kt @@ -8,7 +8,7 @@ class ScamberTraslator : Madara( "ScamberTraslator", "https://scambertraslator.com", "es", - dateFormat = SimpleDateFormat("yyy-MM-dd", Locale.ROOT) + dateFormat = SimpleDateFormat("yyy-MM-dd", Locale.ROOT), ) { override val useNewChapterEndpoint = false } diff --git a/multisrc/overrides/madara/sensainayuri/src/SensainaYuri.kt b/multisrc/overrides/madara/sensainayuri/src/SensainaYuri.kt index a39560c25..cc374ffe1 100644 --- a/multisrc/overrides/madara/sensainayuri/src/SensainaYuri.kt +++ b/multisrc/overrides/madara/sensainayuri/src/SensainaYuri.kt @@ -11,7 +11,7 @@ class SensainaYuri : Madara( "Sensaina Yuri", "https://sensainayuri.dropescan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/shayami/src/Shayami.kt b/multisrc/overrides/madara/shayami/src/Shayami.kt index 7305133df..aeead055c 100644 --- a/multisrc/overrides/madara/shayami/src/Shayami.kt +++ b/multisrc/overrides/madara/shayami/src/Shayami.kt @@ -8,7 +8,7 @@ class Shayami : Madara( "Shayami", "https://shayami.com", "es", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("es")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("es")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/shinzooscan/src/ShinzooScan.kt b/multisrc/overrides/madara/shinzooscan/src/ShinzooScan.kt index c941deade..0ab74816e 100644 --- a/multisrc/overrides/madara/shinzooscan/src/ShinzooScan.kt +++ b/multisrc/overrides/madara/shinzooscan/src/ShinzooScan.kt @@ -11,7 +11,7 @@ class ShinzooScan : Madara( "Shinzoo Scan", "https://shinzooscan.xyz", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/shiraiscans/src/ShiraiScans.kt b/multisrc/overrides/madara/shiraiscans/src/ShiraiScans.kt index 6890a6425..6c03d3877 100644 --- a/multisrc/overrides/madara/shiraiscans/src/ShiraiScans.kt +++ b/multisrc/overrides/madara/shiraiscans/src/ShiraiScans.kt @@ -11,7 +11,7 @@ class ShiraiScans : Madara( "Shirai Scans", "https://shiraiscans.com.br", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/sinensis/src/SinensisScan.kt b/multisrc/overrides/madara/sinensis/src/SinensisScan.kt index a868e56c4..21c19402f 100644 --- a/multisrc/overrides/madara/sinensis/src/SinensisScan.kt +++ b/multisrc/overrides/madara/sinensis/src/SinensisScan.kt @@ -22,7 +22,7 @@ class SinensisScan : Madara( "Sinensis Scan", "https://sinensisscans.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { // Name changed from Sinensis to Sinensis Scan diff --git a/multisrc/overrides/madara/sodascan/src/SodaScan.kt b/multisrc/overrides/madara/sodascan/src/SodaScan.kt index ea6fc3297..ceb6b370f 100644 --- a/multisrc/overrides/madara/sodascan/src/SodaScan.kt +++ b/multisrc/overrides/madara/sodascan/src/SodaScan.kt @@ -11,7 +11,7 @@ class SodaScan : Madara( "SodaScan", "https://sodascan.xyz", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/sweetdesirescan/src/SweetDesireScan.kt b/multisrc/overrides/madara/sweetdesirescan/src/SweetDesireScan.kt index 7395fa984..d5bff18ed 100644 --- a/multisrc/overrides/madara/sweetdesirescan/src/SweetDesireScan.kt +++ b/multisrc/overrides/madara/sweetdesirescan/src/SweetDesireScan.kt @@ -11,7 +11,7 @@ class SweetDesireScan : Madara( "Sweet Desire Scan", "https://sweetdesire.com.br", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/sweettimescan/src/SweetTimeScan.kt b/multisrc/overrides/madara/sweettimescan/src/SweetTimeScan.kt index 48bcb2a70..b2c4cf017 100644 --- a/multisrc/overrides/madara/sweettimescan/src/SweetTimeScan.kt +++ b/multisrc/overrides/madara/sweettimescan/src/SweetTimeScan.kt @@ -14,7 +14,7 @@ class SweetTimeScan : Madara( "Sweet Time Scan", "https://sweetscan.net", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/tatakaescan/src/TatakaeScan.kt b/multisrc/overrides/madara/tatakaescan/src/TatakaeScan.kt index 346b36625..11a086777 100644 --- a/multisrc/overrides/madara/tatakaescan/src/TatakaeScan.kt +++ b/multisrc/overrides/madara/tatakaescan/src/TatakaeScan.kt @@ -11,7 +11,7 @@ class TatakaeScan : Madara( "Tatakae Scan", "https://tatakaescan.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/taurusfansub/src/TaurusFansub.kt b/multisrc/overrides/madara/taurusfansub/src/TaurusFansub.kt index bc48b91fc..b4a38e878 100644 --- a/multisrc/overrides/madara/taurusfansub/src/TaurusFansub.kt +++ b/multisrc/overrides/madara/taurusfansub/src/TaurusFansub.kt @@ -8,7 +8,7 @@ class TaurusFansub : Madara( "Taurus Fansub", "https://taurusfansub.com", "es", - dateFormat = SimpleDateFormat("dd/MM/yyy", Locale.ROOT) + dateFormat = SimpleDateFormat("dd/MM/yyy", Locale.ROOT), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/teenmanhua/src/TeenManhua.kt b/multisrc/overrides/madara/teenmanhua/src/TeenManhua.kt index de663a8c3..49ee68407 100644 --- a/multisrc/overrides/madara/teenmanhua/src/TeenManhua.kt +++ b/multisrc/overrides/madara/teenmanhua/src/TeenManhua.kt @@ -8,5 +8,5 @@ class TeenManhua : Madara( "TeenManhua", "https://teenmanhua.com", "en", - dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US) + dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US), ) diff --git a/multisrc/overrides/madara/thesugar/src/TheSugar.kt b/multisrc/overrides/madara/thesugar/src/TheSugar.kt index 798df7f3d..e233ab367 100644 --- a/multisrc/overrides/madara/thesugar/src/TheSugar.kt +++ b/multisrc/overrides/madara/thesugar/src/TheSugar.kt @@ -11,7 +11,7 @@ class TheSugar : Madara( "The Sugar", "https://thesugarscan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/threequeensscanlator/src/ThreeQueensScanlator.kt b/multisrc/overrides/madara/threequeensscanlator/src/ThreeQueensScanlator.kt index d44a68dcf..a211c93b1 100644 --- a/multisrc/overrides/madara/threequeensscanlator/src/ThreeQueensScanlator.kt +++ b/multisrc/overrides/madara/threequeensscanlator/src/ThreeQueensScanlator.kt @@ -11,7 +11,7 @@ class ThreeQueensScanlator : Madara( "Three Queens Scanlator", "https://tqscan.com.br", "pt-BR", - SimpleDateFormat("dd 'de' MMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/tonizutoon/src/TonizuToon.kt b/multisrc/overrides/madara/tonizutoon/src/TonizuToon.kt index 07f4c519e..65e061210 100644 --- a/multisrc/overrides/madara/tonizutoon/src/TonizuToon.kt +++ b/multisrc/overrides/madara/tonizutoon/src/TonizuToon.kt @@ -8,5 +8,5 @@ class TonizuToon : Madara( "TonizuToon", "https://tonizutoon.com", "tr", - SimpleDateFormat("MMMMM d, yyyy", Locale("tr")) + SimpleDateFormat("MMMMM d, yyyy", Locale("tr")), ) diff --git a/multisrc/overrides/madara/toonily/src/Toonily.kt b/multisrc/overrides/madara/toonily/src/Toonily.kt index 6b3c62153..6acc143eb 100644 --- a/multisrc/overrides/madara/toonily/src/Toonily.kt +++ b/multisrc/overrides/madara/toonily/src/Toonily.kt @@ -8,7 +8,7 @@ class Toonily : Madara( "Toonily", "https://toonily.com", "en", - SimpleDateFormat("MMM d, yy", Locale.US) + SimpleDateFormat("MMM d, yy", Locale.US), ) { // The source customized the Madara theme and broke the filter. diff --git a/multisrc/overrides/madara/tortugaceviri/src/TortugaCeviri.kt b/multisrc/overrides/madara/tortugaceviri/src/TortugaCeviri.kt index 544c44d40..8c2d25b2e 100644 --- a/multisrc/overrides/madara/tortugaceviri/src/TortugaCeviri.kt +++ b/multisrc/overrides/madara/tortugaceviri/src/TortugaCeviri.kt @@ -10,7 +10,7 @@ class TortugaCeviri : Madara( "Tortuga Ceviri", "https://tortuga-ceviri.com", "tr", - SimpleDateFormat("MMM d, yyy", Locale("tr")) + SimpleDateFormat("MMM d, yyy", Locale("tr")), ) { override val versionId = 2 diff --git a/multisrc/overrides/madara/treemanga/src/TreeManga.kt b/multisrc/overrides/madara/treemanga/src/TreeManga.kt index 6c2351fb0..89fe92eb4 100644 --- a/multisrc/overrides/madara/treemanga/src/TreeManga.kt +++ b/multisrc/overrides/madara/treemanga/src/TreeManga.kt @@ -8,7 +8,7 @@ class TreeManga : Madara( "TreeManga", "https://treemanga.com", "en", - dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US) + dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US), ) { override val useNewChapterEndpoint: Boolean = true } diff --git a/multisrc/overrides/madara/tudoquadrinhos/src/TudoQuadrinhos.kt b/multisrc/overrides/madara/tudoquadrinhos/src/TudoQuadrinhos.kt index 46a1f0721..3d7541bda 100644 --- a/multisrc/overrides/madara/tudoquadrinhos/src/TudoQuadrinhos.kt +++ b/multisrc/overrides/madara/tudoquadrinhos/src/TudoQuadrinhos.kt @@ -11,7 +11,7 @@ class TudoQuadrinhos : Madara( "Tudo Quadrinhos", "https://tudoquadrinhos.com.br", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/vermanhwas/src/VerManhwas.kt b/multisrc/overrides/madara/vermanhwas/src/VerManhwas.kt index b0ba50386..9468b1189 100644 --- a/multisrc/overrides/madara/vermanhwas/src/VerManhwas.kt +++ b/multisrc/overrides/madara/vermanhwas/src/VerManhwas.kt @@ -8,7 +8,7 @@ class VerManhwas : Madara( "Ver Manhwas", "https://vermanhwa.com", "es", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("es")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("es")), ) { override val useNewChapterEndpoint = true } diff --git a/multisrc/overrides/madara/visbellum/src/Visbellum.kt b/multisrc/overrides/madara/visbellum/src/Visbellum.kt index bd9eb5913..1421998d2 100644 --- a/multisrc/overrides/madara/visbellum/src/Visbellum.kt +++ b/multisrc/overrides/madara/visbellum/src/Visbellum.kt @@ -11,7 +11,7 @@ class Visbellum : Madara( "Visbellum", "https://visbellum.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/warqueenscan/src/WarQueenScan.kt b/multisrc/overrides/madara/warqueenscan/src/WarQueenScan.kt index 5c7ed8b57..3c485e0d5 100644 --- a/multisrc/overrides/madara/warqueenscan/src/WarQueenScan.kt +++ b/multisrc/overrides/madara/warqueenscan/src/WarQueenScan.kt @@ -11,7 +11,7 @@ class WarQueenScan : Madara( "War Queen Scan", "https://wqscan.com", "pt-BR", - SimpleDateFormat("yyyy-MM-dd", Locale("pt", "BR")) + SimpleDateFormat("yyyy-MM-dd", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/webtoonstop/src/WebtoonsTOP.kt b/multisrc/overrides/madara/webtoonstop/src/WebtoonsTOP.kt index 7b26b7e28..c92056658 100644 --- a/multisrc/overrides/madara/webtoonstop/src/WebtoonsTOP.kt +++ b/multisrc/overrides/madara/webtoonstop/src/WebtoonsTOP.kt @@ -8,5 +8,5 @@ class WebtoonsTOP : Madara( "WebtoonsTOP", "https://webtoons.top", "en", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale.US), ) diff --git a/multisrc/overrides/madara/webtoontr/src/WebtoonTR.kt b/multisrc/overrides/madara/webtoontr/src/WebtoonTR.kt index ce8523bbb..9546d2322 100644 --- a/multisrc/overrides/madara/webtoontr/src/WebtoonTR.kt +++ b/multisrc/overrides/madara/webtoontr/src/WebtoonTR.kt @@ -8,5 +8,5 @@ class WebtoonTR : Madara( "Webtoon TR", "https://webtoon-tr.com", "tr", - SimpleDateFormat("dd/MM/yyy", Locale("tr")) + SimpleDateFormat("dd/MM/yyy", Locale("tr")), ) diff --git a/multisrc/overrides/madara/winterscan/src/WinterScan.kt b/multisrc/overrides/madara/winterscan/src/WinterScan.kt index 4675b1bab..f69111097 100644 --- a/multisrc/overrides/madara/winterscan/src/WinterScan.kt +++ b/multisrc/overrides/madara/winterscan/src/WinterScan.kt @@ -11,7 +11,7 @@ class WinterScan : Madara( "Winter Scan", "https://winterscan.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/wonderlandscan/src/WonderlandScan.kt b/multisrc/overrides/madara/wonderlandscan/src/WonderlandScan.kt index 1a9ae39d7..e8d181dc5 100644 --- a/multisrc/overrides/madara/wonderlandscan/src/WonderlandScan.kt +++ b/multisrc/overrides/madara/wonderlandscan/src/WonderlandScan.kt @@ -11,7 +11,7 @@ class WonderlandScan : Madara( "Wonderland Scan", "https://wonderlandscan.com", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/yanpfansub/src/YANPFansub.kt b/multisrc/overrides/madara/yanpfansub/src/YANPFansub.kt index 9dadd299d..1963f693f 100644 --- a/multisrc/overrides/madara/yanpfansub/src/YANPFansub.kt +++ b/multisrc/overrides/madara/yanpfansub/src/YANPFansub.kt @@ -14,7 +14,7 @@ class YANPFansub : Madara( "YANP Fansub", "https://yanpfansub.com", "pt-BR", - SimpleDateFormat("MMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMM dd, yyyy", Locale("pt", "BR")), ) { // Scanlator changed the theme from WpMangaReader to Madara. diff --git a/multisrc/overrides/madara/yaoicomics/src/YaoiComics.kt b/multisrc/overrides/madara/yaoicomics/src/YaoiComics.kt index a806cc994..2ad1ce7f1 100644 --- a/multisrc/overrides/madara/yaoicomics/src/YaoiComics.kt +++ b/multisrc/overrides/madara/yaoicomics/src/YaoiComics.kt @@ -11,7 +11,7 @@ class YaoiComics : Madara( "Yaoi Comics", "https://ycscan.com", "pt-BR", - SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd 'de' MMMMM 'de' yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/yaoitoshokan/src/YaoiToshokan.kt b/multisrc/overrides/madara/yaoitoshokan/src/YaoiToshokan.kt index 5349ed009..5855a24f7 100644 --- a/multisrc/overrides/madara/yaoitoshokan/src/YaoiToshokan.kt +++ b/multisrc/overrides/madara/yaoitoshokan/src/YaoiToshokan.kt @@ -16,7 +16,7 @@ class YaoiToshokan : Madara( "Yaoi Toshokan", "https://www.yaoitoshokan.net", "pt-BR", - SimpleDateFormat("dd MMM yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd MMM yyyy", Locale("pt", "BR")), ) { override fun headersBuilder(): Headers.Builder = super.headersBuilder() diff --git a/multisrc/overrides/madara/yetiskinruyamanga/src/YetiskinRuyaManga.kt b/multisrc/overrides/madara/yetiskinruyamanga/src/YetiskinRuyaManga.kt index 8e3aa99c1..70cfa6915 100644 --- a/multisrc/overrides/madara/yetiskinruyamanga/src/YetiskinRuyaManga.kt +++ b/multisrc/overrides/madara/yetiskinruyamanga/src/YetiskinRuyaManga.kt @@ -10,7 +10,7 @@ class YetiskinRuyaManga : Madara( "Yetişkin Rüya Manga", "https://yetiskin.ruyamanga.com", "tr", - SimpleDateFormat("dd/MM/yyy", Locale("tr")) + SimpleDateFormat("dd/MM/yyy", Locale("tr")), ) { override val useNewChapterEndpoint = true diff --git a/multisrc/overrides/madara/yokaijump/src/YokaiJump.kt b/multisrc/overrides/madara/yokaijump/src/YokaiJump.kt index c8349ed6e..994596661 100644 --- a/multisrc/overrides/madara/yokaijump/src/YokaiJump.kt +++ b/multisrc/overrides/madara/yokaijump/src/YokaiJump.kt @@ -8,5 +8,5 @@ class YokaiJump : Madara( "Yokai Jump", "https://yokaijump.fr", "fr", - dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US) + dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US), ) diff --git a/multisrc/overrides/madara/yugenmangas/src/YugenMangas.kt b/multisrc/overrides/madara/yugenmangas/src/YugenMangas.kt index 977bac8cb..7688b23a7 100644 --- a/multisrc/overrides/madara/yugenmangas/src/YugenMangas.kt +++ b/multisrc/overrides/madara/yugenmangas/src/YugenMangas.kt @@ -14,7 +14,7 @@ class YugenMangas : Madara( "YugenMangas", "https://yugenmangas.com.br", "pt-BR", - SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() @@ -40,7 +40,7 @@ class YugenMangas : Madara( val chapterUrl = element.selectFirst("a")!!.attr("abs:href") setUrlWithoutDomain( chapterUrl.substringBefore("?style=paged") + - if (!chapterUrl.endsWith(chapterUrlSuffix)) chapterUrlSuffix else "" + if (!chapterUrl.endsWith(chapterUrlSuffix)) chapterUrlSuffix else "", ) } diff --git a/multisrc/overrides/madara/yuriverso/src/YuriVerso.kt b/multisrc/overrides/madara/yuriverso/src/YuriVerso.kt index 8bbda1659..89f599b25 100644 --- a/multisrc/overrides/madara/yuriverso/src/YuriVerso.kt +++ b/multisrc/overrides/madara/yuriverso/src/YuriVerso.kt @@ -11,7 +11,7 @@ class YuriVerso : Madara( "Yuri Verso", "https://yuri.live", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/zeroscan/src/ZeroScan.kt b/multisrc/overrides/madara/zeroscan/src/ZeroScan.kt index 7733dfcac..0738403e3 100644 --- a/multisrc/overrides/madara/zeroscan/src/ZeroScan.kt +++ b/multisrc/overrides/madara/zeroscan/src/ZeroScan.kt @@ -11,7 +11,7 @@ class ZeroScan : Madara( "Zero Scan", "https://zeroscan.com.br", "pt-BR", - SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")) + SimpleDateFormat("dd/MM/yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/madara/zinmanhwa/src/Zinmanhwa.kt b/multisrc/overrides/madara/zinmanhwa/src/Zinmanhwa.kt index acd5d725d..531e8b1ff 100644 --- a/multisrc/overrides/madara/zinmanhwa/src/Zinmanhwa.kt +++ b/multisrc/overrides/madara/zinmanhwa/src/Zinmanhwa.kt @@ -8,5 +8,5 @@ class Zinmanhwa : Madara( "Zinmanhwa", "https://zinmanhwa.com", "en", - dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US) + dateFormat = SimpleDateFormat("dd/MM/yy", Locale.US), ) diff --git a/multisrc/overrides/madtheme/mangapuma/src/MangaPuma.kt b/multisrc/overrides/madtheme/mangapuma/src/MangaPuma.kt index c323d7eb3..54832cb79 100644 --- a/multisrc/overrides/madtheme/mangapuma/src/MangaPuma.kt +++ b/multisrc/overrides/madtheme/mangapuma/src/MangaPuma.kt @@ -6,7 +6,7 @@ class MangaPuma : MadTheme( "MangaPuma", "https://mangapuma.com", - "en" + "en", ) { override val id = 7893483872024027913 } diff --git a/multisrc/overrides/mangabox/mangakakalots/src/Mangakakalots.kt b/multisrc/overrides/mangabox/mangakakalots/src/Mangakakalots.kt index 192448a34..27eeb6d1f 100644 --- a/multisrc/overrides/mangabox/mangakakalots/src/Mangakakalots.kt +++ b/multisrc/overrides/mangabox/mangakakalots/src/Mangakakalots.kt @@ -21,7 +21,7 @@ class Mangakakalots : MangaBox("Mangakakalots (unoriginal)", "https://mangakakal override fun getStatusFilters(): Array> = arrayOf( Pair("all", "ALL"), Pair("Completed", "Completed"), - Pair("Ongoing", "Ongoing") + Pair("Ongoing", "Ongoing"), ) override fun getGenreFilters(): Array> = arrayOf( Pair("all", "ALL"), @@ -64,6 +64,6 @@ class Mangakakalots : MangaBox("Mangakakalots (unoriginal)", "https://mangakakal Pair("Tragedy", "Tragedy"), Pair("Webtoons", "Webtoons"), Pair("Yaoi", "Yaoi"), - Pair("Yuri", "Yuri") + Pair("Yuri", "Yuri"), ) } diff --git a/multisrc/overrides/mangabz/mangabz/src/CookieInterceptor.kt b/multisrc/overrides/mangabz/mangabz/src/CookieInterceptor.kt index 183232fab..6bf204a2d 100644 --- a/multisrc/overrides/mangabz/mangabz/src/CookieInterceptor.kt +++ b/multisrc/overrides/mangabz/mangabz/src/CookieInterceptor.kt @@ -8,7 +8,7 @@ import okhttp3.Response class CookieInterceptor( private val domain: String, private val key: String, - private val value: String + private val value: String, ) : Interceptor { init { diff --git a/multisrc/overrides/mangabz/mangabz/src/Filters.kt b/multisrc/overrides/mangabz/mangabz/src/Filters.kt index bd8e5cfe9..b3843888f 100644 --- a/multisrc/overrides/mangabz/mangabz/src/Filters.kt +++ b/multisrc/overrides/mangabz/mangabz/src/Filters.kt @@ -8,9 +8,11 @@ import org.jsoup.select.Evaluator fun getFilterListInternal(categories: List): FilterList { val list: List> = if (categories.isEmpty()) { listOf(Filter.Header("点击“重置”刷新分类")) - } else buildList(categories.size + 1) { - add(Filter.Header("分类(搜索文本时无效)")) - categories.mapTo(this, CategoryData::toFilter) + } else { + buildList(categories.size + 1) { + add(Filter.Header("分类(搜索文本时无效)")) + categories.mapTo(this, CategoryData::toFilter) + } } return FilterList(list) } @@ -55,7 +57,7 @@ fun parseCategories(document: Document): List { class CategoryData( private val name: String, private val values: Array, - private val ids: IntArray + private val ids: IntArray, ) { fun toFilter() = CategoryFilter(name, values, ids) } diff --git a/multisrc/overrides/mangacatalog/readattackontitanshingekinokyojinmanga/src/ReadAttackOnTitanShingekiNoKyojinManga.kt b/multisrc/overrides/mangacatalog/readattackontitanshingekinokyojinmanga/src/ReadAttackOnTitanShingekiNoKyojinManga.kt index 8791bb5b6..dd282a206 100644 --- a/multisrc/overrides/mangacatalog/readattackontitanshingekinokyojinmanga/src/ReadAttackOnTitanShingekiNoKyojinManga.kt +++ b/multisrc/overrides/mangacatalog/readattackontitanshingekinokyojinmanga/src/ReadAttackOnTitanShingekiNoKyojinManga.kt @@ -26,7 +26,7 @@ class ReadAttackOnTitanShingekiNoKyojinManga : MangaCatalog("Read Attack on Tita val urlElemnt = element.selectFirst("a") name = listOfNotNull( urlElemnt.text(), - element.selectFirst("div.text-xs").text().takeUnless { it.isBlank() } + element.selectFirst("div.text-xs").text().takeUnless { it.isBlank() }, ).joinToString(" - ") { it.trim() } url = urlElemnt.attr("abs:href") } diff --git a/multisrc/overrides/mangacatalog/readbokunoheroacademiamyheroacademiamanga/src/ReadBokuNoHeroAcademiaMyHeroAcademiaManga.kt b/multisrc/overrides/mangacatalog/readbokunoheroacademiamyheroacademiamanga/src/ReadBokuNoHeroAcademiaMyHeroAcademiaManga.kt index 0db1cdd1f..18f730057 100644 --- a/multisrc/overrides/mangacatalog/readbokunoheroacademiamyheroacademiamanga/src/ReadBokuNoHeroAcademiaMyHeroAcademiaManga.kt +++ b/multisrc/overrides/mangacatalog/readbokunoheroacademiamyheroacademiamanga/src/ReadBokuNoHeroAcademiaMyHeroAcademiaManga.kt @@ -12,6 +12,6 @@ class ReadBokuNoHeroAcademiaMyHeroAcademiaManga : MangaCatalog("Read Boku no Her Pair("Rising", "$baseUrl/manga/deku-bakugo-rising/"), Pair("Colored", "$baseUrl/manga/boku-no-hero-academia-colored/"), Pair("Oumagadoki Zoo", "$baseUrl/manga/oumagadoki-zoo/"), - Pair("Sensei no Bulge", "$baseUrl/manga/sensei-no-bulge/") + Pair("Sensei no Bulge", "$baseUrl/manga/sensei-no-bulge/"), ).sortedBy { it.first }.distinctBy { it.second } } diff --git a/multisrc/overrides/mangacatalog/readkaguyasamamangaonline/src/ReadKaguyaSamaMangaOnline.kt b/multisrc/overrides/mangacatalog/readkaguyasamamangaonline/src/ReadKaguyaSamaMangaOnline.kt index 1bf897e4e..662b15178 100644 --- a/multisrc/overrides/mangacatalog/readkaguyasamamangaonline/src/ReadKaguyaSamaMangaOnline.kt +++ b/multisrc/overrides/mangacatalog/readkaguyasamamangaonline/src/ReadKaguyaSamaMangaOnline.kt @@ -11,6 +11,6 @@ class ReadKaguyaSamaMangaOnline : MangaCatalog("Read Kaguya-sama Manga Online", Pair("Instant Bullet", "$baseUrl/manga/ib-instant-bullet/"), Pair("Oshi no Ko", "$baseUrl/manga/oshi-no-ko/"), Pair("Sayonara Piano Sonata", "$baseUrl/manga/sayonara-piano-sonata/"), - Pair("Original Hinatazaka", "$baseUrl/manga/original-hinatazaka/") + Pair("Original Hinatazaka", "$baseUrl/manga/original-hinatazaka/"), ).sortedBy { it.first }.distinctBy { it.second } } diff --git a/multisrc/overrides/mangacatalog/readtokyoghoulretokyoghoulmangaonline/src/ReadTokyoGhoulReTokyoGhoulMangaOnline.kt b/multisrc/overrides/mangacatalog/readtokyoghoulretokyoghoulmangaonline/src/ReadTokyoGhoulReTokyoGhoulMangaOnline.kt index fec751471..47ab4e0a7 100644 --- a/multisrc/overrides/mangacatalog/readtokyoghoulretokyoghoulmangaonline/src/ReadTokyoGhoulReTokyoGhoulMangaOnline.kt +++ b/multisrc/overrides/mangacatalog/readtokyoghoulretokyoghoulmangaonline/src/ReadTokyoGhoulReTokyoGhoulMangaOnline.kt @@ -10,6 +10,6 @@ class ReadTokyoGhoulReTokyoGhoulMangaOnline : MangaCatalog("Read Tokyo Ghoul Re Pair("TGre Colored", "$baseUrl/manga/tokyo-ghoulre-colored/"), Pair("Gorilla", "$baseUrl/manga/this-gorilla-will-die-in-1-day/"), Pair("ArtBook", "$baseUrl/manga/tokyo-ghoul-zakki/"), - Pair("TG Light Novel", "$baseUrl/manga/tokyo-ghoul-re-light-novels/") + Pair("TG Light Novel", "$baseUrl/manga/tokyo-ghoul-re-light-novels/"), ).sortedBy { it.first }.distinctBy { it.second } } diff --git a/multisrc/overrides/mangadventure/arcrelight/src/ArcRelight.kt b/multisrc/overrides/mangadventure/arcrelight/src/ArcRelight.kt index 801fad0c6..f87ad2478 100644 --- a/multisrc/overrides/mangadventure/arcrelight/src/ArcRelight.kt +++ b/multisrc/overrides/mangadventure/arcrelight/src/ArcRelight.kt @@ -20,6 +20,6 @@ class ArcRelight : MangAdventure("Arc-Relight", "https://arc-relight.com") { "Shounen", "Steins;Gate", "Supernatural", - "Tragedy" + "Tragedy", ) } diff --git a/multisrc/overrides/mangaraw/manga9co/src/MangaRawConstants.kt b/multisrc/overrides/mangaraw/manga9co/src/MangaRawConstants.kt index c6a34973e..f25835f71 100644 --- a/multisrc/overrides/mangaraw/manga9co/src/MangaRawConstants.kt +++ b/multisrc/overrides/mangaraw/manga9co/src/MangaRawConstants.kt @@ -15,12 +15,12 @@ internal fun getSelectors(mirrorIndex: Int) = when (mirrorIndex) { 0, 1, 2 -> Selectors( listMangaSelector = ".card", detailsSelector = "div:has(> main)", - recommendClass = "container" + recommendClass = "container", ) else -> Selectors( listMangaSelector = ".post-list:not(.last-hidden) > .item", detailsSelector = "#post-data", - recommendClass = "post-list" + recommendClass = "post-list", ) } diff --git a/multisrc/overrides/mangaraw/mangarawru/src/MangaRawRU.kt b/multisrc/overrides/mangaraw/mangarawru/src/MangaRawRU.kt index d610438e5..8cc81ef18 100644 --- a/multisrc/overrides/mangaraw/mangarawru/src/MangaRawRU.kt +++ b/multisrc/overrides/mangaraw/mangarawru/src/MangaRawRU.kt @@ -63,7 +63,6 @@ class MangaRawRU : MangaRawTheme("MangaRawRU", "https://mangaraw.ru") { } override fun pageListParse(document: Document): List { - val position = 32 val parser = ImageListParser(document.html(), position) diff --git a/multisrc/overrides/mangasar/mangasup/src/MangasUp.kt b/multisrc/overrides/mangasar/mangasup/src/MangasUp.kt index 5de6b25fb..ff4addb2d 100644 --- a/multisrc/overrides/mangasar/mangasup/src/MangasUp.kt +++ b/multisrc/overrides/mangasar/mangasup/src/MangasUp.kt @@ -11,7 +11,7 @@ import org.jsoup.nodes.Element class MangasUp : MangaSar( "MangásUp", "https://mangasup.net", - "pt-BR" + "pt-BR", ) { override fun chapterListPaginatedRequest(mangaUrl: String, page: Int): Request { diff --git a/multisrc/overrides/mangasar/seemangas/src/Seemangas.kt b/multisrc/overrides/mangasar/seemangas/src/Seemangas.kt index 015283032..f2960f42a 100644 --- a/multisrc/overrides/mangasar/seemangas/src/Seemangas.kt +++ b/multisrc/overrides/mangasar/seemangas/src/Seemangas.kt @@ -20,7 +20,7 @@ import org.jsoup.nodes.Element class Seemangas : MangaSar( "Seemangas", "https://seemangas.com", - "pt-BR" + "pt-BR", ) { override fun popularMangaSelector() = "ul.sidebar-popular li.popular-treending" diff --git a/multisrc/overrides/mangathemesia/arcanescan/src/Arcanescan.kt b/multisrc/overrides/mangathemesia/arcanescan/src/Arcanescan.kt index 853860a5e..835f25440 100644 --- a/multisrc/overrides/mangathemesia/arcanescan/src/Arcanescan.kt +++ b/multisrc/overrides/mangathemesia/arcanescan/src/Arcanescan.kt @@ -8,5 +8,5 @@ class Arcanescan : MangaThemesia( "Arcane scan", "https://arcanescan.fr", "fr", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale.FRANCE) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale.FRANCE), ) diff --git a/multisrc/overrides/mangathemesia/asurascans/src/AsuraScans.kt b/multisrc/overrides/mangathemesia/asurascans/src/AsuraScans.kt index 29b599102..ecd8a0304 100644 --- a/multisrc/overrides/mangathemesia/asurascans/src/AsuraScans.kt +++ b/multisrc/overrides/mangathemesia/asurascans/src/AsuraScans.kt @@ -20,12 +20,12 @@ import java.util.concurrent.TimeUnit open class AsuraScans( override val baseUrl: String, override val lang: String, - dateFormat: SimpleDateFormat + dateFormat: SimpleDateFormat, ) : MangaThemesia( "Asura Scans", baseUrl, lang, - dateFormat = dateFormat + dateFormat = dateFormat, ), ConfigurableSource { @@ -56,7 +56,7 @@ open class AsuraScans( return this.map { mangasPage -> MangasPage( mangasPage.mangas.map { it.tempUrlToPermIfNeeded() }, - mangasPage.hasNextPage + mangasPage.hasNextPage, ) } } diff --git a/multisrc/overrides/mangathemesia/asurascans/src/AsuraScansFactory.kt b/multisrc/overrides/mangathemesia/asurascans/src/AsuraScansFactory.kt index 945681019..74c0c44a4 100644 --- a/multisrc/overrides/mangathemesia/asurascans/src/AsuraScansFactory.kt +++ b/multisrc/overrides/mangathemesia/asurascans/src/AsuraScansFactory.kt @@ -10,7 +10,7 @@ import java.util.Locale class AsuraScansFactory : SourceFactory { override fun createSources() = listOf( AsuraScansEn(), - AsuraScansTr() + AsuraScansTr(), ) } diff --git a/multisrc/overrides/mangathemesia/constellarscans/src/ConstellarScans.kt b/multisrc/overrides/mangathemesia/constellarscans/src/ConstellarScans.kt index 36494fabb..47b647980 100644 --- a/multisrc/overrides/mangathemesia/constellarscans/src/ConstellarScans.kt +++ b/multisrc/overrides/mangathemesia/constellarscans/src/ConstellarScans.kt @@ -65,7 +65,7 @@ class ConstellarScans : MangaThemesia("Constellar Scans", "https://constellarsca super.pageListRequest(chapter).newBuilder() .header( "Accept", - "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9" + "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9", ) .header("Sec-Fetch-Site", "same-origin") .header("Sec-Fetch-Mode", "navigate") diff --git a/multisrc/overrides/mangathemesia/diskusscan/src/DiskusScan.kt b/multisrc/overrides/mangathemesia/diskusscan/src/DiskusScan.kt index 59b237dcc..bb45ae628 100644 --- a/multisrc/overrides/mangathemesia/diskusscan/src/DiskusScan.kt +++ b/multisrc/overrides/mangathemesia/diskusscan/src/DiskusScan.kt @@ -11,7 +11,7 @@ class DiskusScan : MangaThemesia( "Diskus Scan", "https://diskusscan.com", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { // Changed their theme from Madara to MangaThemesia. diff --git a/multisrc/overrides/mangathemesia/flamescans/src/FlameScans.kt b/multisrc/overrides/mangathemesia/flamescans/src/FlameScans.kt index 90d8a56dc..89187f6f3 100644 --- a/multisrc/overrides/mangathemesia/flamescans/src/FlameScans.kt +++ b/multisrc/overrides/mangathemesia/flamescans/src/FlameScans.kt @@ -34,13 +34,13 @@ open class FlameScans( override val baseUrl: String, override val lang: String, mangaUrlDirectory: String, - dateFormat: SimpleDateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.US) + dateFormat: SimpleDateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.US), ) : MangaThemesia( "Flame Scans", baseUrl, lang, mangaUrlDirectory = mangaUrlDirectory, - dateFormat = dateFormat + dateFormat = dateFormat, ), ConfigurableSource { @@ -154,7 +154,7 @@ open class FlameScans( return this.map { mangasPage -> MangasPage( mangasPage.mangas.map { it.tempUrlToPermIfNeeded() }, - mangasPage.hasNextPage + mangasPage.hasNextPage, ) } } diff --git a/multisrc/overrides/mangathemesia/flamescans/src/FlameScansFactory.kt b/multisrc/overrides/mangathemesia/flamescans/src/FlameScansFactory.kt index abaad4e68..a617de108 100644 --- a/multisrc/overrides/mangathemesia/flamescans/src/FlameScansFactory.kt +++ b/multisrc/overrides/mangathemesia/flamescans/src/FlameScansFactory.kt @@ -7,7 +7,7 @@ import java.util.concurrent.TimeUnit class FlameScansFactory : SourceFactory { override fun createSources() = listOf( - FlameScansEn() + FlameScansEn(), ) } diff --git a/multisrc/overrides/mangathemesia/franxxmangas/src/FranxxMangas.kt b/multisrc/overrides/mangathemesia/franxxmangas/src/FranxxMangas.kt index 2ecb426bd..1c5733419 100644 --- a/multisrc/overrides/mangathemesia/franxxmangas/src/FranxxMangas.kt +++ b/multisrc/overrides/mangathemesia/franxxmangas/src/FranxxMangas.kt @@ -11,7 +11,7 @@ class FranxxMangas : MangaThemesia( "Franxx Mangás", "https://franxxmangas.net", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = network.cloudflareClient.newBuilder() diff --git a/multisrc/overrides/mangathemesia/iimanga/src/ARESManga.kt b/multisrc/overrides/mangathemesia/iimanga/src/ARESManga.kt index bf4612a35..dcea745a6 100644 --- a/multisrc/overrides/mangathemesia/iimanga/src/ARESManga.kt +++ b/multisrc/overrides/mangathemesia/iimanga/src/ARESManga.kt @@ -9,7 +9,7 @@ class ARESManga : MangaThemesia( "https://aresmanga.net", "ar", mangaUrlDirectory = "/series", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("ar")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("ar")), ) { // The scanlator changed their name. override val id: Long = 230017529540228175 diff --git a/multisrc/overrides/mangathemesia/imaginescan/src/ImagineScan.kt b/multisrc/overrides/mangathemesia/imaginescan/src/ImagineScan.kt index 1b06da15e..65bd371c4 100644 --- a/multisrc/overrides/mangathemesia/imaginescan/src/ImagineScan.kt +++ b/multisrc/overrides/mangathemesia/imaginescan/src/ImagineScan.kt @@ -11,7 +11,7 @@ class ImagineScan : MangaThemesia( "Imagine Scan", "https://imaginescan.com.br", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/mangathemesia/inarimanga/src/InariManga.kt b/multisrc/overrides/mangathemesia/inarimanga/src/InariManga.kt index 51dbd9c5e..c411ce9a2 100644 --- a/multisrc/overrides/mangathemesia/inarimanga/src/InariManga.kt +++ b/multisrc/overrides/mangathemesia/inarimanga/src/InariManga.kt @@ -8,5 +8,5 @@ class InariManga : MangaThemesia( "InariManga", "https://inarimanga.com", "es", - dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale("es")) + dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale("es")), ) diff --git a/multisrc/overrides/mangathemesia/komikav/src/KomikAV.kt b/multisrc/overrides/mangathemesia/komikav/src/KomikAV.kt index e31f5f527..c2c577036 100644 --- a/multisrc/overrides/mangathemesia/komikav/src/KomikAV.kt +++ b/multisrc/overrides/mangathemesia/komikav/src/KomikAV.kt @@ -14,7 +14,7 @@ class KomikAV : MangaThemesia( "Komik AV (WP Manga Stream)", "https://komikav.com", "id", - dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.forLanguageTag("id")) + dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.forLanguageTag("id")), ) { // Formerly "Komik AV (WP Manga Stream)" override val id = 7875815514004535629 diff --git a/multisrc/overrides/mangathemesia/komikcast/src/KomikCast.kt b/multisrc/overrides/mangathemesia/komikcast/src/KomikCast.kt index 24a9a3622..89d3147a6 100644 --- a/multisrc/overrides/mangathemesia/komikcast/src/KomikCast.kt +++ b/multisrc/overrides/mangathemesia/komikcast/src/KomikCast.kt @@ -24,7 +24,7 @@ class KomikCast : MangaThemesia( "Komik Cast", baseUrl = "https://komikcast.site", "id", - mangaUrlDirectory = "/daftar-komik" + mangaUrlDirectory = "/daftar-komik", ) { // Formerly "Komik Cast (WP Manga Stream)" override val id = 972717448578983812 @@ -186,8 +186,8 @@ class KomikCast : MangaThemesia( arrayOf( Pair("All", ""), Pair("Ongoing", "ongoing"), - Pair("Completed", "completed") - ) + Pair("Completed", "completed"), + ), ) private class TypeFilter : SelectFilter( @@ -196,8 +196,8 @@ class KomikCast : MangaThemesia( Pair("All", ""), Pair("Manga", "manga"), Pair("Manhwa", "manhwa"), - Pair("Manhua", "manhua") - ) + Pair("Manhua", "manhua"), + ), ) private class OrderByFilter(defaultOrder: String? = null) : SelectFilter( @@ -207,9 +207,9 @@ class KomikCast : MangaThemesia( Pair("A-Z", "titleasc"), Pair("Z-A", "titledesc"), Pair("Update", "update"), - Pair("Popular", "popular") + Pair("Popular", "popular"), ), - defaultOrder + defaultOrder, ) override fun getFilterList(): FilterList { @@ -228,7 +228,7 @@ class KomikCast : MangaThemesia( Filter.Header("NOTE: Can't be used with other filter!"), Filter.Header("$name Project List page"), ProjectFilter(), - ) + ), ) } return FilterList(filters) diff --git a/multisrc/overrides/mangathemesia/komiklab/src/KomikLabFactory.kt b/multisrc/overrides/mangathemesia/komiklab/src/KomikLabFactory.kt index 56f4413a0..ae1b9ee32 100644 --- a/multisrc/overrides/mangathemesia/komiklab/src/KomikLabFactory.kt +++ b/multisrc/overrides/mangathemesia/komiklab/src/KomikLabFactory.kt @@ -6,7 +6,7 @@ import eu.kanade.tachiyomi.source.SourceFactory class KomikLabFactory : SourceFactory { override fun createSources() = listOf( KomikLabEn(), - KomikLabId() + KomikLabId(), ) } diff --git a/multisrc/overrides/mangathemesia/komikmama/src/KomikMama.kt b/multisrc/overrides/mangathemesia/komikmama/src/KomikMama.kt index 10dd420a8..05af4faf3 100644 --- a/multisrc/overrides/mangathemesia/komikmama/src/KomikMama.kt +++ b/multisrc/overrides/mangathemesia/komikmama/src/KomikMama.kt @@ -5,6 +5,8 @@ import java.text.SimpleDateFormat import java.util.Locale class KomikMama : MangaThemesia( - "KomikMama", "https://komikmama.co", "id", - dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale("id")) + "KomikMama", + "https://komikmama.co", + "id", + dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale("id")), ) diff --git a/multisrc/overrides/mangathemesia/mangacim/src/Mangacim.kt b/multisrc/overrides/mangathemesia/mangacim/src/Mangacim.kt index a96b02d61..23ab9fb9c 100644 --- a/multisrc/overrides/mangathemesia/mangacim/src/Mangacim.kt +++ b/multisrc/overrides/mangathemesia/mangacim/src/Mangacim.kt @@ -8,5 +8,5 @@ class Mangacim : MangaThemesia( "Mangacim", "https://www.mangacim.com", "tr", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("tr")), ) diff --git a/multisrc/overrides/mangathemesia/mangaschan/src/MangasChan.kt b/multisrc/overrides/mangathemesia/mangaschan/src/MangasChan.kt index 248247368..20823174d 100644 --- a/multisrc/overrides/mangathemesia/mangaschan/src/MangasChan.kt +++ b/multisrc/overrides/mangathemesia/mangaschan/src/MangasChan.kt @@ -11,7 +11,7 @@ class MangasChan : MangaThemesia( "Mangás Chan", "https://mangaschan.com", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = network.cloudflareClient.newBuilder() diff --git a/multisrc/overrides/mangathemesia/mangaswat/src/MangaSwat.kt b/multisrc/overrides/mangathemesia/mangaswat/src/MangaSwat.kt index ea97a5476..723a9bafb 100644 --- a/multisrc/overrides/mangathemesia/mangaswat/src/MangaSwat.kt +++ b/multisrc/overrides/mangathemesia/mangaswat/src/MangaSwat.kt @@ -15,7 +15,7 @@ class MangaSwat : MangaThemesia( "MangaSwat", "https://swatmanga.net", "ar", - dateFormat = SimpleDateFormat("yyyy-MM-dd", Locale.US) + dateFormat = SimpleDateFormat("yyyy-MM-dd", Locale.US), ) { override val client: OkHttpClient = super.client.newBuilder() .rateLimit(1) diff --git a/multisrc/overrides/mangathemesia/mangkomik/src/MangKomik.kt b/multisrc/overrides/mangathemesia/mangkomik/src/MangKomik.kt index e675ad57a..cd466067b 100644 --- a/multisrc/overrides/mangathemesia/mangkomik/src/MangKomik.kt +++ b/multisrc/overrides/mangathemesia/mangkomik/src/MangKomik.kt @@ -17,7 +17,7 @@ class MangKomik : MangaThemesia("MangKomik", "https://mangkomik.net", "id") { } val scriptResponse = client.newCall( - GET(scriptUrl, headers) + GET(scriptUrl, headers), ).execute() // Inject external JS diff --git a/multisrc/overrides/mangathemesia/manhwaindo/src/ManhwaIndo.kt b/multisrc/overrides/mangathemesia/manhwaindo/src/ManhwaIndo.kt index 53a391e2c..365a2d8b5 100644 --- a/multisrc/overrides/mangathemesia/manhwaindo/src/ManhwaIndo.kt +++ b/multisrc/overrides/mangathemesia/manhwaindo/src/ManhwaIndo.kt @@ -7,8 +7,11 @@ import java.text.SimpleDateFormat import java.util.Locale class ManhwaIndo : MangaThemesia( - "Manhwa Indo", "https://manhwaindo.id", "id", "/series", - SimpleDateFormat("MMMM dd, yyyy", Locale("id")) + "Manhwa Indo", + "https://manhwaindo.id", + "id", + "/series", + SimpleDateFormat("MMMM dd, yyyy", Locale("id")), ) { override fun headersBuilder(): Headers.Builder = Headers.Builder() diff --git a/multisrc/overrides/mangathemesia/miauscan/src/MiauScanFactory.kt b/multisrc/overrides/mangathemesia/miauscan/src/MiauScanFactory.kt index a2e5bfa76..1e3d18ae1 100644 --- a/multisrc/overrides/mangathemesia/miauscan/src/MiauScanFactory.kt +++ b/multisrc/overrides/mangathemesia/miauscan/src/MiauScanFactory.kt @@ -14,7 +14,7 @@ import java.util.Locale class MiauScanFactory : SourceFactory { override fun createSources() = listOf( MiauScan("es", Filter.TriState.STATE_EXCLUDE), - MiauScan("pt-BR", Filter.TriState.STATE_INCLUDE) + MiauScan("pt-BR", Filter.TriState.STATE_INCLUDE), ) } @@ -22,7 +22,7 @@ open class MiauScan(lang: String, private val portugueseMode: Int) : MangaThemes name = "Miau Scan", baseUrl = "https://miauscan.com", lang = lang, - dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale("es")) + dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale("es")), ) { override fun searchMangaRequest(page: Int, query: String, filters: FilterList): Request { @@ -32,8 +32,8 @@ open class MiauScan(lang: String, private val portugueseMode: Int) : MangaThemes val overloadedGenreFilter = GenreListFilter( genres = genreFilter.state + listOf( - Genre("", PORTUGUESE_GENRE, portugueseMode) - ) + Genre("", PORTUGUESE_GENRE, portugueseMode), + ), ) val overloadedFilters = filters.toMutableList().apply { diff --git a/multisrc/overrides/mangathemesia/mihentai/src/Mihentai.kt b/multisrc/overrides/mangathemesia/mihentai/src/Mihentai.kt index d6900620a..8bdb74c0c 100644 --- a/multisrc/overrides/mangathemesia/mihentai/src/Mihentai.kt +++ b/multisrc/overrides/mangathemesia/mihentai/src/Mihentai.kt @@ -10,8 +10,8 @@ class Mihentai : MangaThemesia("Mihentai", "https://mihentai.com", "all") { Pair("All", ""), Pair("Publishing", "publishing"), Pair("Finished", "finished"), - Pair("Dropped", "drop") - ) + Pair("Dropped", "drop"), + ), ) private class TypeFilter : SelectFilter( @@ -23,8 +23,8 @@ class Mihentai : MangaThemesia("Mihentai", "https://mihentai.com", "all") { Pair("Manhua", "Manhua"), Pair("Webtoon", "webtoon"), Pair("One-Shot", "One-Shot"), - Pair("Doujin", "doujin") - ) + Pair("Doujin", "doujin"), + ), ) override fun getFilterList(): FilterList = FilterList( @@ -32,7 +32,7 @@ class Mihentai : MangaThemesia("Mihentai", "https://mihentai.com", "all") { StatusFilter(), TypeFilter(), OrderByFilter(), - GenreListFilter(getGenreList()) - ) + GenreListFilter(getGenreList()), + ), ) } diff --git a/multisrc/overrides/mangathemesia/modescanlator/src/ModeScanlator.kt b/multisrc/overrides/mangathemesia/modescanlator/src/ModeScanlator.kt index 56c4215be..fc7300559 100644 --- a/multisrc/overrides/mangathemesia/modescanlator/src/ModeScanlator.kt +++ b/multisrc/overrides/mangathemesia/modescanlator/src/ModeScanlator.kt @@ -12,7 +12,7 @@ class ModeScanlator : MangaThemesia( "https://modescanlator.com", "pt-BR", mangaUrlDirectory = "/projetos", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { // Site changed from Madara to WpMangaReader. diff --git a/multisrc/overrides/mangathemesia/mundomangakun/src/MundoMangaKun.kt b/multisrc/overrides/mangathemesia/mundomangakun/src/MundoMangaKun.kt index f7c37d432..1ff549b3b 100644 --- a/multisrc/overrides/mangathemesia/mundomangakun/src/MundoMangaKun.kt +++ b/multisrc/overrides/mangathemesia/mundomangakun/src/MundoMangaKun.kt @@ -11,7 +11,7 @@ class MundoMangaKun : MangaThemesia( "Mundo Mangá-Kun", "https://mundomangakun.com.br", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { // Changed their theme from a custom one to MangaThemesia. diff --git a/multisrc/overrides/mangathemesia/origamiorpheans/src/OrigamiOrpheans.kt b/multisrc/overrides/mangathemesia/origamiorpheans/src/OrigamiOrpheans.kt index 039c4f207..d437bb177 100644 --- a/multisrc/overrides/mangathemesia/origamiorpheans/src/OrigamiOrpheans.kt +++ b/multisrc/overrides/mangathemesia/origamiorpheans/src/OrigamiOrpheans.kt @@ -11,7 +11,7 @@ class OrigamiOrpheans : MangaThemesia( "Origami Orpheans", "https://origami-orpheans.com.br", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { // Scanlator migrated from Madara to WpMangaReader. diff --git a/multisrc/overrides/mangathemesia/ozulscans/src/OzulScans.kt b/multisrc/overrides/mangathemesia/ozulscans/src/OzulScans.kt index 7c3d8b75d..126a4adf0 100644 --- a/multisrc/overrides/mangathemesia/ozulscans/src/OzulScans.kt +++ b/multisrc/overrides/mangathemesia/ozulscans/src/OzulScans.kt @@ -8,5 +8,5 @@ class OzulScans : MangaThemesia( "Ozul Scans", "https://ozulscans.com", "ar", - dateFormat = SimpleDateFormat("MMM d, yyy", Locale("ar")) + dateFormat = SimpleDateFormat("MMM d, yyy", Locale("ar")), ) diff --git a/multisrc/overrides/mangathemesia/phoenixfansub/src/PhoenixFansub.kt b/multisrc/overrides/mangathemesia/phoenixfansub/src/PhoenixFansub.kt index 5b2fdbf33..588b0f471 100644 --- a/multisrc/overrides/mangathemesia/phoenixfansub/src/PhoenixFansub.kt +++ b/multisrc/overrides/mangathemesia/phoenixfansub/src/PhoenixFansub.kt @@ -8,7 +8,7 @@ class PhoenixFansub : MangaThemesia( "Phoenix Fansub", "https://phoenixfansub.com", "es", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale("es")) + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale("es")), ) { override val altNamePrefix: String = "Nombre alternativo: " diff --git a/multisrc/overrides/mangathemesia/sheamanga/src/SheaManga.kt b/multisrc/overrides/mangathemesia/sheamanga/src/SheaManga.kt index 341f6cff7..fb19b54e8 100644 --- a/multisrc/overrides/mangathemesia/sheamanga/src/SheaManga.kt +++ b/multisrc/overrides/mangathemesia/sheamanga/src/SheaManga.kt @@ -12,7 +12,7 @@ class SheaManga : MangaThemesia( "Shea Manga", "https://sheakomik.com", "id", - dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.forLanguageTag("id")) + dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.forLanguageTag("id")), ) { override val client: OkHttpClient = network.cloudflareClient.newBuilder() diff --git a/multisrc/overrides/mangathemesia/silencescan/src/SilenceScan.kt b/multisrc/overrides/mangathemesia/silencescan/src/SilenceScan.kt index 37f3f80c4..da1b6dcfe 100644 --- a/multisrc/overrides/mangathemesia/silencescan/src/SilenceScan.kt +++ b/multisrc/overrides/mangathemesia/silencescan/src/SilenceScan.kt @@ -12,7 +12,7 @@ class SilenceScan : MangaThemesia( "Silence Scan", "https://silencescan.com.br", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val versionId: Int = 2 diff --git a/multisrc/overrides/mangathemesia/summerfansub/src/SummerFansub.kt b/multisrc/overrides/mangathemesia/summerfansub/src/SummerFansub.kt index ee9375c8f..52b05083a 100644 --- a/multisrc/overrides/mangathemesia/summerfansub/src/SummerFansub.kt +++ b/multisrc/overrides/mangathemesia/summerfansub/src/SummerFansub.kt @@ -11,7 +11,7 @@ class SummerFansub : MangaThemesia( "Summer Fansub", "https://smmr.in", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM dd, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/mangathemesia/tsundokutraducoes/src/TsundokuTraducoes.kt b/multisrc/overrides/mangathemesia/tsundokutraducoes/src/TsundokuTraducoes.kt index 01f514367..66e4a8bda 100644 --- a/multisrc/overrides/mangathemesia/tsundokutraducoes/src/TsundokuTraducoes.kt +++ b/multisrc/overrides/mangathemesia/tsundokutraducoes/src/TsundokuTraducoes.kt @@ -11,7 +11,7 @@ class TsundokuTraducoes : MangaThemesia( "Tsundoku Traduções", "https://tsundoku.com.br", "pt-BR", - dateFormat = SimpleDateFormat("MMMMM d, yyyy", Locale("pt", "BR")) + dateFormat = SimpleDateFormat("MMMMM d, yyyy", Locale("pt", "BR")), ) { override val client: OkHttpClient = network.cloudflareClient.newBuilder() diff --git a/multisrc/overrides/mangathemesia/turktoon/src/TurkToon.kt b/multisrc/overrides/mangathemesia/turktoon/src/TurkToon.kt index 625cee0a7..a08ab361d 100644 --- a/multisrc/overrides/mangathemesia/turktoon/src/TurkToon.kt +++ b/multisrc/overrides/mangathemesia/turktoon/src/TurkToon.kt @@ -5,6 +5,8 @@ import java.text.SimpleDateFormat import java.util.Locale class TurkToon : MangaThemesia( - "TurkToon", "https://turktoon.com", "tr", - dateFormat = SimpleDateFormat("MMM d, yyyy", Locale("tr")) + "TurkToon", + "https://turktoon.com", + "tr", + dateFormat = SimpleDateFormat("MMM d, yyyy", Locale("tr")), ) diff --git a/multisrc/overrides/mangathemesia/worldromancetranslation/src/WorldRomanceTranslation.kt b/multisrc/overrides/mangathemesia/worldromancetranslation/src/WorldRomanceTranslation.kt index 8bfdd991d..47629eda5 100644 --- a/multisrc/overrides/mangathemesia/worldromancetranslation/src/WorldRomanceTranslation.kt +++ b/multisrc/overrides/mangathemesia/worldromancetranslation/src/WorldRomanceTranslation.kt @@ -11,7 +11,7 @@ class WorldRomanceTranslation : MangaThemesia( "World Romance Translation", "https://wrt.my.id", "id", - dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale("id")) + dateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale("id")), ) { override val projectPageString = "/project-wrt" diff --git a/multisrc/overrides/mccms/haoman6_glens/res/mipmap-hdpi/ic_launcher.png b/multisrc/overrides/mccms/haoman6glens/res/mipmap-hdpi/ic_launcher.png similarity index 100% rename from multisrc/overrides/mccms/haoman6_glens/res/mipmap-hdpi/ic_launcher.png rename to multisrc/overrides/mccms/haoman6glens/res/mipmap-hdpi/ic_launcher.png diff --git a/multisrc/overrides/mccms/haoman6_glens/res/mipmap-mdpi/ic_launcher.png b/multisrc/overrides/mccms/haoman6glens/res/mipmap-mdpi/ic_launcher.png similarity index 100% rename from multisrc/overrides/mccms/haoman6_glens/res/mipmap-mdpi/ic_launcher.png rename to multisrc/overrides/mccms/haoman6glens/res/mipmap-mdpi/ic_launcher.png diff --git a/multisrc/overrides/mccms/haoman6_glens/res/mipmap-xhdpi/ic_launcher.png b/multisrc/overrides/mccms/haoman6glens/res/mipmap-xhdpi/ic_launcher.png similarity index 100% rename from multisrc/overrides/mccms/haoman6_glens/res/mipmap-xhdpi/ic_launcher.png rename to multisrc/overrides/mccms/haoman6glens/res/mipmap-xhdpi/ic_launcher.png diff --git a/multisrc/overrides/mccms/haoman6_glens/res/mipmap-xxhdpi/ic_launcher.png b/multisrc/overrides/mccms/haoman6glens/res/mipmap-xxhdpi/ic_launcher.png similarity index 100% rename from multisrc/overrides/mccms/haoman6_glens/res/mipmap-xxhdpi/ic_launcher.png rename to multisrc/overrides/mccms/haoman6glens/res/mipmap-xxhdpi/ic_launcher.png diff --git a/multisrc/overrides/mccms/haoman6_glens/res/mipmap-xxxhdpi/ic_launcher.png b/multisrc/overrides/mccms/haoman6glens/res/mipmap-xxxhdpi/ic_launcher.png similarity index 100% rename from multisrc/overrides/mccms/haoman6_glens/res/mipmap-xxxhdpi/ic_launcher.png rename to multisrc/overrides/mccms/haoman6glens/res/mipmap-xxxhdpi/ic_launcher.png diff --git a/multisrc/overrides/mccms/haoman6_glens/res/web_hi_res_512.png b/multisrc/overrides/mccms/haoman6glens/res/web_hi_res_512.png similarity index 100% rename from multisrc/overrides/mccms/haoman6_glens/res/web_hi_res_512.png rename to multisrc/overrides/mccms/haoman6glens/res/web_hi_res_512.png diff --git a/multisrc/overrides/mccms/haoman6_glens/src/Haoman6_glens.kt b/multisrc/overrides/mccms/haoman6glens/src/Haoman6glens.kt similarity index 67% rename from multisrc/overrides/mccms/haoman6_glens/src/Haoman6_glens.kt rename to multisrc/overrides/mccms/haoman6glens/src/Haoman6glens.kt index d892edd09..7b0ff5e58 100644 --- a/multisrc/overrides/mccms/haoman6_glens/src/Haoman6_glens.kt +++ b/multisrc/overrides/mccms/haoman6glens/src/Haoman6glens.kt @@ -1,9 +1,9 @@ -package eu.kanade.tachiyomi.extension.zh.haoman6_glens +package eu.kanade.tachiyomi.extension.zh.haoman6glens import eu.kanade.tachiyomi.multisrc.mccms.MCCMSWeb import eu.kanade.tachiyomi.source.model.SManga -class Haoman6_glens : MCCMSWeb("好漫6 (g-lens)", "https://www.g-lens.com") { +class Haoman6glens : MCCMSWeb("好漫6 (g-lens)", "https://www.g-lens.com") { override fun SManga.cleanup() = apply { title = title.removeSuffix("_").removeSuffix("-").removeSuffix("漫画") } diff --git a/multisrc/overrides/mmrcms/animaregia/src/AnimaRegia.kt b/multisrc/overrides/mmrcms/animaregia/src/AnimaRegia.kt index bbc81b218..87c89f0e9 100644 --- a/multisrc/overrides/mmrcms/animaregia/src/AnimaRegia.kt +++ b/multisrc/overrides/mmrcms/animaregia/src/AnimaRegia.kt @@ -27,7 +27,7 @@ class AnimaRegia : MMRCMS("AnimaRegia", "https://animaregia.net", "pt-BR") { it.copy( mangas = it.mangas.map { manga -> manga.apply { title = title.removeSuffix(LANGUAGE_SUFFIX) } - } + }, ) } } @@ -49,7 +49,7 @@ class AnimaRegia : MMRCMS("AnimaRegia", "https://animaregia.net", "pt-BR") { it.copy( mangas = it.mangas.map { manga -> manga.apply { title = title.removeSuffix(LANGUAGE_SUFFIX) } - } + }, ) } } @@ -61,7 +61,7 @@ class AnimaRegia : MMRCMS("AnimaRegia", "https://animaregia.net", "pt-BR") { title = document.selectFirst("h1.widget-title").text() thumbnail_url = coverGuess( document.select("div.col-sm-5 img.img-thumbnail").firstOrNull()?.attr("abs:src"), - document.location() + document.location(), ) description = document.select("div.row div.well p").text().trim() diff --git a/multisrc/overrides/mmrcms/gekkouhentai/src/GekkouHentai.kt b/multisrc/overrides/mmrcms/gekkouhentai/src/GekkouHentai.kt index a81f27042..e020f8198 100644 --- a/multisrc/overrides/mmrcms/gekkouhentai/src/GekkouHentai.kt +++ b/multisrc/overrides/mmrcms/gekkouhentai/src/GekkouHentai.kt @@ -11,7 +11,7 @@ import java.util.concurrent.TimeUnit class GekkouHentai : MMRCMS( "Gekkou Hentai", "https://hentai.gekkouscans.com.br", - "pt-BR" + "pt-BR", ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/mmrcms/gekkouscan/src/GekkouScans.kt b/multisrc/overrides/mmrcms/gekkouscan/src/GekkouScans.kt index ad02e44c8..3b46df13a 100644 --- a/multisrc/overrides/mmrcms/gekkouscan/src/GekkouScans.kt +++ b/multisrc/overrides/mmrcms/gekkouscan/src/GekkouScans.kt @@ -14,7 +14,7 @@ import java.util.concurrent.TimeUnit class GekkouScans : MMRCMS( "Gekkou Scans", "https://gekkou.com.br", - "pt-BR" + "pt-BR", ) { override val client: OkHttpClient = super.client.newBuilder() diff --git a/multisrc/overrides/multichan/henchan/src/HenChan.kt b/multisrc/overrides/multichan/henchan/src/HenChan.kt index 3dd65239b..8ee7ec2fc 100644 --- a/multisrc/overrides/multichan/henchan/src/HenChan.kt +++ b/multisrc/overrides/multichan/henchan/src/HenChan.kt @@ -41,7 +41,6 @@ class HenChan : MultiChan("HenChan", "http://y.hchan.live", "ru"), ConfigurableS override val baseUrl = domain override fun searchMangaRequest(page: Int, query: String, filters: FilterList): Request { - val url = if (query.isNotEmpty()) { "$baseUrl/?do=search&subaction=search&story=$query&search_start=$page" } else { @@ -93,14 +92,14 @@ class HenChan : MultiChan("HenChan", "http://y.hchan.live", "ru"), ConfigurableS return this.replace(regex, "showfull_retina/manga") .replace( "_".plus(URL(baseUrl).host), - "_hentaichan.ru" + "_hentaichan.ru", ) // domain-related replacing for very old mangas .plus( if (isExHenManga) { "#" } else { "" - } + }, ) // # for later so we know what type manga is it } @@ -122,17 +121,19 @@ class HenChan : MultiChan("HenChan", "http://y.hchan.live", "ru"), ConfigurableS if (!response.isSuccessful) { response.close() // Error message for exceeding last page - if (response.code == 404) + if (response.code == 404) { Observable.just( listOf( SChapter.create().apply { url = manga.url name = "Chapter" chapter_number = 1f - } - ) + }, + ), ) - else throw Exception("HTTP error ${response.code}") + } else { + throw Exception("HTTP error ${response.code}") + } } } .map { response -> @@ -188,20 +189,20 @@ class HenChan : MultiChan("HenChan", "http://y.hchan.live", "ru"), ConfigurableS result.addAll( document.select(chapterListSelector()).map { chapterFromElement(it) - } + }, ) var url = document.select("div#pagination_related a:contains(Вперед)").attr("href") while (url.isNotBlank()) { val get = GET( "${response.request.url}/$url", - headers = headers + headers = headers, ) val nextPage = client.newCall(get).execute().asJsoup() result.addAll( nextPage.select(chapterListSelector()).map { chapterFromElement(it) - } + }, ) url = nextPage.select("div#pagination_related a:contains(Вперед)").attr("href") @@ -247,7 +248,7 @@ class HenChan : MultiChan("HenChan", "http://y.hchan.live", "ru"), ConfigurableS private class Genre( val id: String, - @SuppressLint("DefaultLocale") name: String = id.replace('_', ' ').capitalize() + @SuppressLint("DefaultLocale") name: String = id.replace('_', ' ').capitalize(), ) : Filter.TriState(name) private class GenreList(genres: List) : Filter.Group("Тэги", genres) @@ -258,15 +259,15 @@ class HenChan : MultiChan("HenChan", "http://y.hchan.live", "ru"), ConfigurableS arrayOf( "manga/new&n=dateasc" to "manga/new", "manga/new&n=favasc" to "mostfavorites&sort=manga", - "manga/new&n=abcdesc" to "manga/new&n=abcasc" - ) + "manga/new&n=abcdesc" to "manga/new&n=abcasc", + ), ) private open class UriPartFilter( displayName: String, sortNames: Array, val withGenres: Array>, - val withoutGenres: Array> + val withoutGenres: Array>, ) : Filter.Sort(displayName, sortNames, Selection(1, false)) { fun toUriPartWithGenres() = @@ -278,7 +279,7 @@ class HenChan : MultiChan("HenChan", "http://y.hchan.live", "ru"), ConfigurableS override fun getFilterList() = FilterList( OrderBy(), - GenreList(getGenreList()) + GenreList(getGenreList()), ) private fun getGenreList() = listOf( @@ -457,7 +458,7 @@ class HenChan : MultiChan("HenChan", "http://y.hchan.live", "ru"), ConfigurableS Genre("юмор"), Genre("юри"), Genre("яндере"), - Genre("яой") + Genre("яой"), ) override fun setupPreferenceScreen(screen: androidx.preference.PreferenceScreen) { diff --git a/multisrc/overrides/multichan/mangachan/src/MangaChan.kt b/multisrc/overrides/multichan/mangachan/src/MangaChan.kt index 1a5612c88..24065d942 100644 --- a/multisrc/overrides/multichan/mangachan/src/MangaChan.kt +++ b/multisrc/overrides/multichan/mangachan/src/MangaChan.kt @@ -19,7 +19,6 @@ class MangaChan : MultiChan("MangaChan", "https://manga-chan.me", "ru") { val url = if (query.isNotEmpty()) { "$baseUrl/?do=search&subaction=search&story=$query&search_start=$pageNum" } else { - var genres = "" var order = "" var statusParam = true @@ -90,13 +89,13 @@ class MangaChan : MultiChan("MangaChan", "https://manga-chan.me", "ru") { private class OrderBy : Filter.Sort( "Сортировка", arrayOf("Дата", "Популярность", "Имя", "Главы"), - Selection(1, false) + Selection(1, false), ) override fun getFilterList() = FilterList( Status(), OrderBy(), - GenreList(getGenreList()) + GenreList(getGenreList()), ) private fun getGenreList() = listOf( @@ -154,6 +153,6 @@ class MangaChan : MultiChan("MangaChan", "https://manga-chan.me", "ru") { Genre("эротика"), Genre("юри"), Genre("яой"), - Genre("ёнкома") + Genre("ёнкома"), ) } diff --git a/multisrc/overrides/multichan/yaoichan/src/YaoiChan.kt b/multisrc/overrides/multichan/yaoichan/src/YaoiChan.kt index 9f6515a41..ab11d57f9 100644 --- a/multisrc/overrides/multichan/yaoichan/src/YaoiChan.kt +++ b/multisrc/overrides/multichan/yaoichan/src/YaoiChan.kt @@ -14,7 +14,6 @@ class YaoiChan : MultiChan("YaoiChan", "https://yaoi-chan.me", "ru") { val url = if (query.isNotEmpty()) { "$baseUrl/?do=search&subaction=search&story=$query&search_start=$page" } else { - var genres = "" var order = "" var statusParam = true @@ -85,13 +84,13 @@ class YaoiChan : MultiChan("YaoiChan", "https://yaoi-chan.me", "ru") { private class OrderBy : Filter.Sort( "Сортировка", arrayOf("Дата", "Популярность", "Имя", "Главы"), - Selection(1, false) + Selection(1, false), ) override fun getFilterList() = FilterList( Status(), OrderBy(), - GenreList(getGenreList()) + GenreList(getGenreList()), ) private fun getGenreList() = listOf( @@ -155,6 +154,6 @@ class YaoiChan : MultiChan("YaoiChan", "https://yaoi-chan.me", "ru") { Genre("юмор"), Genre("юри"), Genre("яой"), - Genre("ёнкома") + Genre("ёнкома"), ) } diff --git a/multisrc/overrides/sinmh/gufengmh/src/Gufengmh.kt b/multisrc/overrides/sinmh/gufengmh/src/Gufengmh.kt index f51d3c609..8a703cc90 100644 --- a/multisrc/overrides/sinmh/gufengmh/src/Gufengmh.kt +++ b/multisrc/overrides/sinmh/gufengmh/src/Gufengmh.kt @@ -15,8 +15,9 @@ class Gufengmh : SinMH("古风漫画网", "https://www.123gf.com") { super.mangaDetailsParse(document).apply { if (status == SManga.COMPLETED) return@apply val firstChapter = document.selectFirst(".chapter-body li > a") ?: return@apply - if (firstChapter.attr("href").startsWith("javascript")) + if (firstChapter.attr("href").startsWith("javascript")) { status = SManga.LICENSED + } } override fun fetchChapterList(manga: SManga): Observable> = diff --git a/multisrc/overrides/sinmh/wuqimanga/src/WuqiManga.kt b/multisrc/overrides/sinmh/wuqimanga/src/WuqiManga.kt index 2d2353800..20ed9df20 100644 --- a/multisrc/overrides/sinmh/wuqimanga/src/WuqiManga.kt +++ b/multisrc/overrides/sinmh/wuqimanga/src/WuqiManga.kt @@ -92,8 +92,9 @@ class WuqiManga : SinMH("57漫画", "http://www.wuqimh.net") { val tagMap = filterMap[name]!! for (tag in tags) { val tagName = tag.text() - if (!tagMap.containsKey(tagName)) + if (!tagMap.containsKey(tagName)) { tagMap[tagName] = tag.attr("href").removePrefix("/list/").substringBeforeLast("-order-") + } } } categories = filterMap.map { diff --git a/multisrc/overrides/webtoons/dongmanmanhua/src/DongmanManhua.kt b/multisrc/overrides/webtoons/dongmanmanhua/src/DongmanManhua.kt index 04af41e8e..510d57ed2 100644 --- a/multisrc/overrides/webtoons/dongmanmanhua/src/DongmanManhua.kt +++ b/multisrc/overrides/webtoons/dongmanmanhua/src/DongmanManhua.kt @@ -40,8 +40,11 @@ class DongmanManhua : Webtoons("Dongman Manhua", "https://www.dongmanmanhua.cn", while (continueParsing) { document.select(chapterListSelector()).map { chapters.add(chapterFromElement(it)) } document.select("div.paginate a[onclick] + a").let { element -> - if (element.isNotEmpty()) document = client.newCall(GET(element.attr("abs:href"), headers)).execute().asJsoup() - else continueParsing = false + if (element.isNotEmpty()) { + document = client.newCall(GET(element.attr("abs:href"), headers)).execute().asJsoup() + } else { + continueParsing = false + } } } return chapters diff --git a/multisrc/overrides/webtoons/webtoons/src/WebtoonsFactory.kt b/multisrc/overrides/webtoons/webtoons/src/WebtoonsFactory.kt index 9a3664e75..3d89e60a6 100644 --- a/multisrc/overrides/webtoons/webtoons/src/WebtoonsFactory.kt +++ b/multisrc/overrides/webtoons/webtoons/src/WebtoonsFactory.kt @@ -25,7 +25,7 @@ class WebtoonsID : WebtoonsSrc("Webtoons.com", "https://www.webtoons.com", "id") // Android seems to be unable to parse Indonesian dates; we'll use a short hard-coded table // instead. private val dateMap: Array = arrayOf( - "Jan", "Feb", "Mar", "Apr", "Mei", "Jun", "Jul", "Agu", "Sep", "Okt", "Nov", "Des" + "Jan", "Feb", "Mar", "Apr", "Mei", "Jun", "Jul", "Agu", "Sep", "Okt", "Nov", "Des", ) override fun chapterParseDate(date: String): Long { @@ -39,7 +39,7 @@ class WebtoonsTH : WebtoonsSrc("Webtoons.com", "https://www.webtoons.com", "th", class WebtoonsES : WebtoonsSrc("Webtoons.com", "https://www.webtoons.com", "es") { // Android seems to be unable to parse es dates like Indonesian; we'll use a short hard-coded table instead. private val dateMap: Array = arrayOf( - "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sep", "oct", "nov", "dic" + "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sep", "oct", "nov", "dic", ) override fun chapterParseDate(date: String): Long { diff --git a/multisrc/overrides/webtoons/webtoons/src/WebtoonsSrc.kt b/multisrc/overrides/webtoons/webtoons/src/WebtoonsSrc.kt index 2698a9cc0..6218bf040 100644 --- a/multisrc/overrides/webtoons/webtoons/src/WebtoonsSrc.kt +++ b/multisrc/overrides/webtoons/webtoons/src/WebtoonsSrc.kt @@ -25,7 +25,7 @@ open class WebtoonsSrc( override val lang: String, langCode: String = lang, override val localeForCookie: String = lang, - dateFormat: SimpleDateFormat = SimpleDateFormat("MMM d, yyyy", Locale.ENGLISH) + dateFormat: SimpleDateFormat = SimpleDateFormat("MMM d, yyyy", Locale.ENGLISH), ) : ConfigurableSource, Webtoons(name, baseUrl, lang, langCode, localeForCookie, dateFormat) { override val client: OkHttpClient = super.client.newBuilder() @@ -60,12 +60,12 @@ open class WebtoonsSrc( val note = document.select("div.comment_area div.info_area p").text() if (note.isNotEmpty()) { - val creator = document.select("div.creator_note span.author a").text().trim() pages = pages + Page( - pages.size, "", - TextInterceptorHelper.createUrl(creator, note) + pages.size, + "", + TextInterceptorHelper.createUrl(creator, note), ) } } diff --git a/multisrc/overrides/wpcomics/nettruyen/src/NetTruyen.kt b/multisrc/overrides/wpcomics/nettruyen/src/NetTruyen.kt index cad3b6b84..63930748a 100644 --- a/multisrc/overrides/wpcomics/nettruyen/src/NetTruyen.kt +++ b/multisrc/overrides/wpcomics/nettruyen/src/NetTruyen.kt @@ -15,7 +15,7 @@ class NetTruyen : WPComics("NetTruyen", "https://www.nettruyenking.com", "vi", S override fun getFilterList(): FilterList { return FilterList( StatusFilter(getStatusList()), - GenreFilter(getGenreList()) + GenreFilter(getGenreList()), ) } } diff --git a/multisrc/overrides/wpcomics/truyenchon/src/TruyenChon.kt b/multisrc/overrides/wpcomics/truyenchon/src/TruyenChon.kt index b83cba0aa..2d37a2dfa 100644 --- a/multisrc/overrides/wpcomics/truyenchon/src/TruyenChon.kt +++ b/multisrc/overrides/wpcomics/truyenchon/src/TruyenChon.kt @@ -18,7 +18,7 @@ class TruyenChon : WPComics("TruyenChon", "http://truyenchon.com", "vi", SimpleD override fun getFilterList(): FilterList { return FilterList( StatusFilter(getStatusList()), - GenreFilter(getGenreList()) + GenreFilter(getGenreList()), ) } override fun popularMangaFromElement(element: Element): SManga { diff --git a/multisrc/overrides/zmanga/komikita/src/Komikita.kt b/multisrc/overrides/zmanga/komikita/src/Komikita.kt index f4748280b..325ea1134 100644 --- a/multisrc/overrides/zmanga/komikita/src/Komikita.kt +++ b/multisrc/overrides/zmanga/komikita/src/Komikita.kt @@ -15,7 +15,7 @@ class Komikita : ZManga( "Komikita", "https://komikita.org", "id", - SimpleDateFormat("MMM d, yyyy", Locale("id")) + SimpleDateFormat("MMM d, yyyy", Locale("id")), ) { override val hasProjectPage = true @@ -72,7 +72,7 @@ class Komikita : ZManga( Filter.Header("NOTE: cant be used with other filter!"), Filter.Header("$name Project List page"), ProjectFilter(), - ) + ), ) } return FilterList(filters) @@ -151,7 +151,7 @@ class Komikita : ZManga( Tag("vampire", "Vampire"), Tag("webtoons", "Webtoons"), Tag("yuri", "Yuri"), - Tag("zombies", "Zombies") + Tag("zombies", "Zombies"), ) private class Tag(val id: String, name: String) : Filter.CheckBox(name) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/a3manga/A3Manga.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/a3manga/A3Manga.kt index 512bf63b9..e446544f1 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/a3manga/A3Manga.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/a3manga/A3Manga.kt @@ -71,7 +71,7 @@ open class A3Manga( fetchMangaDetails( SManga.create().apply { url = "/truyen-tranh/$id/" - } + }, ) .map { it.url = "/truyen-tranh/$id/" diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/a3manga/A3MangaUrlActivity.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/a3manga/A3MangaUrlActivity.kt index 936a2d15f..218130652 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/a3manga/A3MangaUrlActivity.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/a3manga/A3MangaUrlActivity.kt @@ -22,7 +22,7 @@ class A3MangaUrlActivity : Activity() { action = "eu.kanade.tachiyomi.SEARCH" putExtra("query", "id:$id") putExtra("filter", packageName) - } + }, ) } catch (e: ActivityNotFoundException) { Log.e("A3MangaThemeUrlActivity", e.toString()) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakamanga/BakaManga.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakamanga/BakaManga.kt index 7c37e311c..d6c5fafa1 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakamanga/BakaManga.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakamanga/BakaManga.kt @@ -17,7 +17,7 @@ import java.util.Calendar abstract class BakaManga( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = true @@ -155,7 +155,7 @@ abstract class BakaManga( override fun getFilterList() = FilterList( Filter.Header("NOTE: Ignored if using text search!"), Filter.Separator(), - GenreFilter(getGenreList()) + GenreFilter(getGenreList()), ) class GenreFilter(vals: Array>) : UriPartFilter("Category", vals) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinGenerator.kt index 582207080..73c6ddfe2 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinGenerator.kt @@ -13,7 +13,7 @@ class BakkinGenerator : ThemeSourceGenerator { override val sources = listOf( SingleLang("Bakkin", "https://bakkin.moe/reader/", "en"), SingleLang("Bakkin Self-hosted", "", "en", className = "BakkinSelfHosted"), - SingleLang("UltraLight Scans", "https://readlight.org/", "en", className = "UltraLightScans") + SingleLang("UltraLight Scans", "https://readlight.org/", "en", className = "UltraLightScans"), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinJSON.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinJSON.kt index a1cd6b1b6..8b5d0e308 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinJSON.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinJSON.kt @@ -7,13 +7,13 @@ internal data class Series( val author: String?, val status: String?, val thumb: String?, - val volumes: List + val volumes: List, ) : Iterable { override fun iterator() = volumes.flatMap { vol -> vol.map { it.copy( name = "$vol - $it", - dir = "$dir/${vol.dir}/${it.dir}" + dir = "$dir/${vol.dir}/${it.dir}", ) } }.iterator() @@ -28,7 +28,7 @@ internal data class Series( internal data class Volume( val dir: String, val name: String, - val chapters: List + val chapters: List, ) : Iterable by chapters { override fun toString() = name.ifEmpty { dir } } @@ -37,7 +37,7 @@ internal data class Volume( internal data class Chapter( val dir: String, val name: String, - val pages: List + val pages: List, ) : Iterable by pages { val number: Float get() = dir.substringAfterLast('c').toFloatOrNull() ?: -1f diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinReaderX.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinReaderX.kt index e39b01618..b9e627d8f 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinReaderX.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bakkin/BakkinReaderX.kt @@ -25,7 +25,7 @@ import uy.kohesive.injekt.api.get abstract class BakkinReaderX( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ConfigurableSource, HttpSource() { override val supportsLatest = false diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/Bilibili.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/Bilibili.kt index 9589afa47..42f3067c2 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/Bilibili.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/Bilibili.kt @@ -37,7 +37,7 @@ import java.util.Locale abstract class Bilibili( override val name: String, final override val baseUrl: String, - final override val lang: String + final override val lang: String, ) : HttpSource(), ConfigurableSource { override val supportsLatest = true @@ -77,8 +77,8 @@ abstract class Bilibili( page = page, query = "", filters = FilterList( - SortFilter("", getAllSortOptions(), defaultPopularSort) - ) + SortFilter("", getAllSortOptions(), defaultPopularSort), + ), ) override fun popularMangaParse(response: Response): MangasPage = searchMangaParse(response) @@ -87,8 +87,8 @@ abstract class Bilibili( page = page, query = "", filters = FilterList( - SortFilter("", getAllSortOptions(), defaultLatestSort) - ) + SortFilter("", getAllSortOptions(), defaultLatestSort), + ), ) override fun latestUpdatesParse(response: Response): MangasPage = searchMangaParse(response) @@ -119,10 +119,13 @@ abstract class Bilibili( } val requestBody = jsonPayload.toString().toRequestBody(JSON_MEDIA_TYPE) - val refererUrl = if (query.isBlank()) "$baseUrl/genre" else + val refererUrl = if (query.isBlank()) { + "$baseUrl/genre" + } else { "$baseUrl/search".toHttpUrl().newBuilder() .addQueryParameter("keyword", query) .toString() + } val newHeaders = headersBuilder() .set("Referer", refererUrl) @@ -354,7 +357,7 @@ abstract class Bilibili( SortFilter(intl.sortLabel, getAllSortOptions(), defaultPopularSort), PriceFilter(intl.priceLabel, getAllPrices()).takeIf { allPrices.isNotEmpty() }, GenreFilter(intl.genreLabel, getAllGenres()), - AreaFilter(intl.areaLabel, allAreas).takeIf { allAreas.isNotEmpty() } + AreaFilter(intl.areaLabel, allAreas).takeIf { allAreas.isNotEmpty() }, ) return FilterList(filters) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/BilibiliDto.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/BilibiliDto.kt index bf267e067..3d5e2c70c 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/BilibiliDto.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/BilibiliDto.kt @@ -7,12 +7,12 @@ import kotlinx.serialization.Serializable data class BilibiliResultDto( val code: Int = 0, val data: T? = null, - @SerialName("msg") val message: String = "" + @SerialName("msg") val message: String = "", ) @Serializable data class BilibiliSearchDto( - val list: List = emptyList() + val list: List = emptyList(), ) @Serializable @@ -28,7 +28,7 @@ data class BilibiliComicDto( val styles: List = emptyList(), val title: String, @SerialName("update_weekday") val updateWeekdays: List = emptyList(), - @SerialName("vertical_cover") val verticalCover: String = "" + @SerialName("vertical_cover") val verticalCover: String = "", ) { val hasPaidChapters: Boolean get() = paidChaptersCount > 0 @@ -49,19 +49,19 @@ data class BilibiliEpisodeDto( @SerialName("pay_mode") val payMode: Int, @SerialName("pub_time") val publicationTime: String, @SerialName("short_title") val shortTitle: String, - val title: String + val title: String, ) @Serializable data class BilibiliReader( - val images: List = emptyList() + val images: List = emptyList(), ) @Serializable data class BilibiliImageDto( val path: String, @SerialName("x") val width: Int, - @SerialName("y") val height: Int + @SerialName("y") val height: Int, ) { fun url(quality: String, format: String): String { @@ -74,40 +74,40 @@ data class BilibiliImageDto( @Serializable data class BilibiliPageDto( val token: String, - val url: String + val url: String, ) @Serializable data class BilibiliAccessTokenCookie( val accessToken: String, val refreshToken: String, - val area: String + val area: String, ) @Serializable data class BilibiliAccessToken( @SerialName("access_token") val accessToken: String, - @SerialName("refresh_token") val refreshToken: String + @SerialName("refresh_token") val refreshToken: String, ) @Serializable data class BilibiliUserEpisodes( - @SerialName("unlocked_eps") val unlockedEpisodes: List? = emptyList() + @SerialName("unlocked_eps") val unlockedEpisodes: List? = emptyList(), ) @Serializable data class BilibiliUnlockedEpisode( - @SerialName("ep_id") val id: Int = 0 + @SerialName("ep_id") val id: Int = 0, ) @Serializable data class BilibiliGetCredential( @SerialName("comic_id") val comicId: Int, @SerialName("ep_id") val episodeId: Int, - val type: Int + val type: Int, ) @Serializable data class BilibiliCredential( - val credential: String + val credential: String, ) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/BilibiliGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/BilibiliGenerator.kt index 073795dbd..45f91190c 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/BilibiliGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/bilibili/BilibiliGenerator.kt @@ -18,7 +18,7 @@ class BilibiliGenerator : ThemeSourceGenerator { baseUrl = "https://www.bilibilicomics.com", langs = listOf("en", "zh-Hans", "id", "es", "fr"), className = "BilibiliComicsFactory", - overrideVersionCode = 3 + overrideVersionCode = 3, ), SingleLang( name = "BILIBILI MANGA", @@ -26,8 +26,8 @@ class BilibiliGenerator : ThemeSourceGenerator { lang = "zh-Hans", className = "BilibiliManga", sourceName = "哔哩哔哩漫画", - overrideVersionCode = 2 - ) + overrideVersionCode = 2, + ), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/comicake/ComiCake.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/comicake/ComiCake.kt index 12bc68983..078115c1e 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/comicake/ComiCake.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/comicake/ComiCake.kt @@ -24,7 +24,7 @@ abstract class ComiCake( final override val baseUrl: String, override val lang: String, readerEndpoint: String = COMICAKE_DEFAULT_READER_ENDPOINT, - apiEndpoint: String = COMICAKE_DEFAULT_API_ENDPOINT + apiEndpoint: String = COMICAKE_DEFAULT_API_ENDPOINT, ) : HttpSource() { override val versionId = 1 @@ -60,8 +60,9 @@ abstract class ComiCake( if (nested) { val nestedComic = obj.getJSONObject("comic") val id = nestedComic.getInt("id") - if (ids.contains(id)) + if (ids.contains(id)) { continue + } ids.add(id) val manga = SManga.create() manga.url = id.toString() @@ -69,8 +70,9 @@ abstract class ComiCake( mangas.add(manga) } else { val id = obj.getInt("id") - if (ids.contains(id)) + if (ids.contains(id)) { continue + } ids.add(id) mangas.add(parseComicJson(obj)) } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/comicake/ComiCakeGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/comicake/ComiCakeGenerator.kt index 58bf697ca..c1abc5148 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/comicake/ComiCakeGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/comicake/ComiCakeGenerator.kt @@ -12,7 +12,7 @@ class ComiCakeGenerator : ThemeSourceGenerator { override val baseVersionCode: Int = 1 override val sources = listOf( - SingleLang("WhimSubs", "https://whimsubs.xyz", "en") + SingleLang("WhimSubs", "https://whimsubs.xyz", "en"), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/eromuse/EroMuse.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/eromuse/EroMuse.kt index 5cf63985d..d5a697d8f 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/eromuse/EroMuse.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/eromuse/EroMuse.kt @@ -93,7 +93,7 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht fun internalParse(internalDocument: Document): List { val authorDocument = if (stackItem.pageType == VARIOUS_AUTHORS) { internalDocument.select(albumSelector)?.let { - elements -> + elements -> elements.reversed().map { pageStack.addLast(StackItem(it.attr("abs:href"), AUTHOR)) } } client.newCall(stackRequest()).execute().asJsoup() @@ -108,7 +108,7 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht val mangas = when (stackItem.pageType) { VARIOUS_AUTHORS -> { document.select(albumSelector)?.let { - elements -> + elements -> elements.reversed().map { pageStack.addLast(StackItem(it.attr("abs:href"), AUTHOR)) } } internalParse(document) @@ -268,7 +268,7 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht SChapter.create().apply { name = it.text() setUrlWithoutDomain(it.attr("href")) - } + }, ) } @@ -279,7 +279,7 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht SChapter.create().apply { name = "Chapter" setUrlWithoutDomain(response.request.url.toString()) - } + }, ) } } @@ -300,14 +300,13 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht fun parsePages( document: Document, nestedChapterDocuments: ArrayDeque = ArrayDeque(), - pages: ArrayList = ArrayList() + pages: ArrayList = ArrayList(), ): List { - // Nested chapters aka folders document.select(linkedChapterSelector) .mapNotNull { nestedChapterDocuments.add( - client.newCall(GET(it.attr("abs:href"), headers)).execute().asJsoup() + client.newCall(GET(it.attr("abs:href"), headers)).execute().asJsoup(), ) } @@ -315,11 +314,11 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht pages.addAll( document.select(pageThumbnailSelector).mapIndexed { i, img -> Page(lastPage + i, "", img.imgAttr().replace(pageThumbnailPathSegment, pageFullSizePathSegment)) - } + }, ) document.nextPageOrNull()?.let { - url -> + url -> pages.addAll(parsePages(client.newCall(GET(url, headers)).execute().asJsoup(), nestedChapterDocuments, pages)) } @@ -342,7 +341,7 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht Filter.Header("Text search only combines with sort!"), Filter.Separator(), AlbumFilter(getAlbumList()), - SortFilter(getSortList()) + SortFilter(getSortList()), ) } @@ -423,7 +422,7 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht Triple("Markydaysaid Comics", "album/Markydaysaid-Comics", AUTHOR), Triple("Central Comics", "album/Central-Comics", AUTHOR), Triple("Frozen Parody Comics", "album/Frozen-Parody-Comics", AUTHOR), - Triple("Blacknwhitecomics.com Comix", "album/Blacknwhitecomics_com-Comix", AUTHOR) + Triple("Blacknwhitecomics.com Comix", "album/Blacknwhitecomics_com-Comix", AUTHOR), ) protected class SortFilter(private val vals: Array>) : Filter.Select("Sort Order", vals.map { it.first }.toTypedArray()) { @@ -433,6 +432,6 @@ open class EroMuse(override val name: String, override val baseUrl: String) : Ht Pair("Views", ""), Pair("Likes", "like"), Pair("Date", "date"), - Pair("A-Z", "az") + Pair("A-Z", "az"), ) } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/eromuse/EroMuseGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/eromuse/EroMuseGenerator.kt index 40a7731a0..97c3e7653 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/eromuse/EroMuseGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/eromuse/EroMuseGenerator.kt @@ -13,7 +13,7 @@ class EroMuseGenerator : ThemeSourceGenerator { override val sources = listOf( SingleLang("8Muses", "https://comics.8muses.com", "en", className = "EightMuses", isNsfw = true, overrideVersionCode = 1), - SingleLang("Erofus", "https://www.erofus.com", "en", isNsfw = true, overrideVersionCode = 1) + SingleLang("Erofus", "https://www.erofus.com", "en", isNsfw = true, overrideVersionCode = 1), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/fmreader/FMReader.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/fmreader/FMReader.kt index da50670d6..c2daf84fe 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/fmreader/FMReader.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/fmreader/FMReader.kt @@ -26,7 +26,7 @@ import java.util.Calendar abstract class FMReader( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = true @@ -88,10 +88,11 @@ abstract class FMReader( 0 -> "name" 1 -> "views" else -> "last_update" - } + }, ) - if (filter.state?.ascending == true) + if (filter.state?.ascending == true) { url.addQueryParameter("sort_type", "ASC") + } } else -> {} } @@ -186,14 +187,16 @@ abstract class FMReader( // languages: en, vi, tr fun parseStatus(status: String?): Int { val completedWords = setOf( - "completed", "complete", - "đã hoàn thành", "hoàn thành", - "tamamlandı" + "completed", + "complete", + "đã hoàn thành", + "hoàn thành", + "tamamlandı", ) val ongoingWords = setOf( "ongoing", "on going", "updating", "incomplete", "chưa hoàn thành", "đang cập nhật", "Đang tiến hành", - "devam ediyor", "Çevirisi Bırakıldı", "Çevirisi Yok" + "devam ediyor", "Çevirisi Bırakıldı", "Çevirisi Yok", ) return when { status == null -> SManga.UNKNOWN @@ -336,7 +339,7 @@ abstract class FMReader( TextField("Group", "group"), Status(), SortBy(), - GenreList(getGenreList()) + GenreList(getGenreList()), ) // [...document.querySelectorAll("div.panel-body a")].map((el,i) => `Genre("${el.innerText.trim()}")`).join(',\n') @@ -380,7 +383,7 @@ abstract class FMReader( Genre("Supernatural"), Genre("Tragedy"), Genre("Adventure"), - Genre("Yaoi") + Genre("Yaoi"), ) // from manhwa18.com/search, removed a few that didn't return results/wouldn't be terribly useful @@ -427,7 +430,7 @@ abstract class FMReader( Genre("Supernatural"), Genre("Tragedy"), Genre("VnComic"), - Genre("Webtoon") + Genre("Webtoon"), ) // taken from readcomiconline.org/search @@ -477,6 +480,6 @@ abstract class FMReader( Genre("VideoGames"), Genre("War"), Genre("Western"), - Genre("Zombies") + Genre("Zombies"), ) } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/foolslide/FoolSlide.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/foolslide/FoolSlide.kt index 4f2fd24ab..42900dc8e 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/foolslide/FoolSlide.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/foolslide/FoolSlide.kt @@ -33,7 +33,7 @@ abstract class FoolSlide( override val name: String, override val baseUrl: String, override val lang: String, - open val urlModifier: String = "" + open val urlModifier: String = "", ) : ConfigurableSource, ParsedHttpSource() { override val supportsLatest = true @@ -53,7 +53,7 @@ abstract class FoolSlide( return mp.copy( mp.mangas.distinctBy { it.url }.filter { latestUpdatesUrls.add(it.url) - } + }, ) } @@ -153,8 +153,9 @@ abstract class FoolSlide( protected open fun parseChapterDate(date: String): Long? { val lcDate = date.lowercase(Locale.ROOT) - if (lcDate.endsWith(" ago")) + if (lcDate.endsWith(" ago")) { parseRelativeDate(lcDate)?.let { return it } + } // Handle 'yesterday' and 'today', using midnight var relativeDate: Calendar? = null @@ -192,10 +193,11 @@ abstract class FoolSlide( var result = DATE_FORMAT_1.parseOrNull(date) for (dateFormat in DATE_FORMATS_WITH_ORDINAL_SUFFIXES) { - if (result == null) + if (result == null) { result = dateFormat.parseOrNull(date) - else + } else { break + } } for (dateFormat in DATE_FORMATS_WITH_ORDINAL_SUFFIXES_NO_YEAR) { @@ -209,7 +211,9 @@ abstract class FoolSlide( set(Calendar.YEAR, Calendar.getInstance().get(Calendar.YEAR)) }.time } - } else break + } else { + break + } } return result?.time ?: 0L diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gattsu/Gattsu.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gattsu/Gattsu.kt index 3d0912bcb..5aecab17a 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gattsu/Gattsu.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gattsu/Gattsu.kt @@ -21,7 +21,7 @@ import java.util.Locale abstract class Gattsu( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = true @@ -135,8 +135,11 @@ abstract class Gattsu( } protected fun Element.imgAttr(): String = - if (hasAttr("data-src")) attr("abs:data-src") - else attr("abs:src") + if (hasAttr("data-src")) { + attr("abs:data-src") + } else { + attr("abs:src") + } protected fun String.toDate(): Long { return try { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gattsu/GattsuGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gattsu/GattsuGenerator.kt index 91e9eaa4d..7df106d59 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gattsu/GattsuGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gattsu/GattsuGenerator.kt @@ -14,7 +14,7 @@ class GattsuGenerator : ThemeSourceGenerator { override val sources = listOf( SingleLang("Hentai Season", "https://hentaiseason.com", "pt-BR", isNsfw = true), SingleLang("Hentai Tokyo", "https://hentaitokyo.net", "pt-BR", isNsfw = true), - SingleLang("Universo Hentai", "https://universohentai.com", "pt-BR", isNsfw = true) + SingleLang("Universo Hentai", "https://universohentai.com", "pt-BR", isNsfw = true), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/genkan/Genkan.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/genkan/Genkan.kt index b7077a955..11373aaca 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/genkan/Genkan.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/genkan/Genkan.kt @@ -102,7 +102,7 @@ open class Genkan( description = document.select("div.col-lg-9").text().substringAfter("Description ").substringBefore(" Volume") thumbnail_url = styleToUrl(document.select("div.media a").first()) genre = listOfNotNull( - document.selectFirst(countryOfOriginSelector)?.let { countryOfOriginToSeriesType(it.text()) } + document.selectFirst(countryOfOriginSelector)?.let { countryOfOriginToSeriesType(it.text()) }, ).joinToString() } @@ -110,7 +110,6 @@ open class Genkan( override fun chapterFromElement(element: Element): SChapter { return SChapter.create().apply { - val urlElement = element.select("a.item-author") val chapNum = urlElement.attr("href").split("/").last() diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/genkan/GenkanOriginal.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/genkan/GenkanOriginal.kt index d632f94da..17b3b68a9 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/genkan/GenkanOriginal.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/genkan/GenkanOriginal.kt @@ -16,7 +16,7 @@ import org.jsoup.select.Elements open class GenkanOriginal( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : Genkan(name, baseUrl, lang) { private var searchQuery = "" diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewer.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewer.kt index 18e40d70a..80fa62acf 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewer.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewer.kt @@ -43,7 +43,7 @@ abstract class GigaViewer( override val name: String, override val baseUrl: String, override val lang: String, - private val cdnUrl: String = "" + private val cdnUrl: String = "", ) : ParsedHttpSource() { override val supportsLatest = true @@ -104,8 +104,9 @@ abstract class GigaViewer( } override fun searchMangaParse(response: Response): MangasPage { - if (response.request.url.toString().contains("search")) + if (response.request.url.toString().contains("search")) { return super.searchMangaParse(response) + } return popularMangaParse(response) } @@ -160,7 +161,7 @@ abstract class GigaViewer( readMoreEndpoint = jsonResult["nextUrl"]!!.jsonPrimitive.content val tempDocument = Jsoup.parse( jsonResult["html"]!!.jsonPrimitive.content, - response.request.url.toString() + response.request.url.toString(), ) tempDocument @@ -237,7 +238,7 @@ abstract class GigaViewer( private class CollectionFilter(val collections: List) : Filter.Select( "コレクション", - collections.toTypedArray() + collections.toTypedArray(), ) { val selected: Collection get() = collections[state] diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewerDto.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewerDto.kt index 2c2d1f7a8..3a210597f 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewerDto.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewerDto.kt @@ -4,17 +4,17 @@ import kotlinx.serialization.Serializable @Serializable data class GigaViewerEpisodeDto( - val readableProduct: GigaViewerReadableProduct + val readableProduct: GigaViewerReadableProduct, ) @Serializable data class GigaViewerReadableProduct( - val pageStructure: GigaViewerPageStructure + val pageStructure: GigaViewerPageStructure, ) @Serializable data class GigaViewerPageStructure( - val pages: List = emptyList() + val pages: List = emptyList(), ) @Serializable @@ -22,5 +22,5 @@ data class GigaViewerPage( val height: Int = 0, val src: String = "", val type: String = "", - val width: Int = 0 + val width: Int = 0, ) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewerGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewerGenerator.kt index da9d02c92..f20c617fc 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewerGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/gigaviewer/GigaViewerGenerator.kt @@ -21,7 +21,7 @@ class GigaViewerGenerator : ThemeSourceGenerator { SingleLang("Magazine Pocket", "https://pocket.shonenmagazine.com", "ja"), SingleLang("Shonen Jump+", "https://shonenjumpplus.com", "ja", pkgName = "shonenjumpplus", className = "ShonenJumpPlus", overrideVersionCode = 2), SingleLang("Sunday Web Every", "https://www.sunday-webry.com", "ja"), - SingleLang("Tonari no Young Jump", "https://tonarinoyj.jp", "ja", className = "TonariNoYoungJump") + SingleLang("Tonari no Young Jump", "https://tonarinoyj.jp", "ja", className = "TonariNoYoungJump"), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/grouple/GroupLe.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/grouple/GroupLe.kt index db4b7e21e..9ff758c68 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/grouple/GroupLe.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/grouple/GroupLe.kt @@ -34,7 +34,7 @@ import java.util.regex.Pattern abstract class GroupLe( override val name: String, override val baseUrl: String, - final override val lang: String + final override val lang: String, ) : ConfigurableSource, ParsedHttpSource() { private val preferences: SharedPreferences by lazy { @@ -48,8 +48,9 @@ abstract class GroupLe( .addNetworkInterceptor { chain -> val originalRequest = chain.request() val response = chain.proceed(originalRequest) - if (originalRequest.url.toString().contains(baseUrl) and (originalRequest.url.toString().contains("internal/redirect") or (response.code == 301))) + if (originalRequest.url.toString().contains(baseUrl) and (originalRequest.url.toString().contains("internal/redirect") or (response.code == 301))) { throw IOException("Ссылка на мангу была изменена. Перемегрируйте мангу на тотже (или смежный с GroupLe) источник или передабавте из Поисковика/Каталога.") + } response } .build() @@ -236,13 +237,15 @@ abstract class GroupLe( val single = Regex("""\s*Сингл\s*""") when { extra.containsMatchIn(chapter.name) -> { - if (chapter.name.substringAfter("Экстра").trim().isEmpty()) + if (chapter.name.substringAfter("Экстра").trim().isEmpty()) { chapter.name = chapter.name.replaceFirst(" ", " - " + DecimalFormat("#,###.##").format(chapter.chapter_number).replace(",", ".") + " ") + } } single.containsMatchIn(chapter.name) -> { - if (chapter.name.substringAfter("Сингл").trim().isEmpty()) + if (chapter.name.substringAfter("Сингл").trim().isEmpty()) { chapter.name = DecimalFormat("#,###.##").format(chapter.chapter_number).replace(",", ".") + " " + chapter.name + } } } } @@ -281,10 +284,13 @@ abstract class GroupLe( urlParts[1] + urlParts[0] + urlParts[2] } } - if (!url.contains("://")) + if (!url.contains("://")) { url = "https:$url" - if (url.contains("one-way.work")) // domain that does not need a token + } + if (url.contains("one-way.work")) { + // domain that does not need a token url = url.substringBefore("?") + } pages.add(Page(i++, "", url.replace("//resh", "//h"))) } return pages diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/grouple/GroupLeGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/grouple/GroupLeGenerator.kt index daa342f68..151ba91d0 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/grouple/GroupLeGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/grouple/GroupLeGenerator.kt @@ -16,7 +16,7 @@ class GroupLeGenerator : ThemeSourceGenerator { SingleLang("MintManga", "https://mintmanga.live", "ru", overrideVersionCode = 46), SingleLang("AllHentai", "http://allhen.online", "ru", isNsfw = true, overrideVersionCode = 22), SingleLang("SelfManga", "https://selfmanga.live", "ru", overrideVersionCode = 22), - SingleLang("RuMIX", "https://rumix.me", "ru", overrideVersionCode = 1) + SingleLang("RuMIX", "https://rumix.me", "ru", overrideVersionCode = 1), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/guya/Guya.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/guya/Guya.kt index 7859adf5d..a0f578be6 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/guya/Guya.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/guya/Guya.kt @@ -31,7 +31,7 @@ import uy.kohesive.injekt.api.get abstract class Guya( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ConfigurableSource, HttpSource() { override val supportsLatest = true @@ -42,7 +42,7 @@ abstract class Guya( "User-Agent", "(Android ${Build.VERSION.RELEASE}; " + "${Build.MANUFACTURER} ${Build.MODEL}) " + - "Tachiyomi/${AppInfo.getVersionName()} ${Build.ID}" + "Tachiyomi/${AppInfo.getVersionName()} ${Build.ID}", ) private val scanlators: ScanlatorStore = ScanlatorStore() @@ -183,7 +183,7 @@ abstract class Guya( "folder", json.getJSONObject("chapters") .getJSONObject(chapterNum) - .getString("folder") + .getString("folder"), ) return parsePageFromJson(pages, metadata) @@ -328,7 +328,7 @@ abstract class Guya( it + 1, "", pages.optJSONObject(it)?.getString("src") - ?: pages[it].toString() + ?: pages[it].toString(), ) } } @@ -364,8 +364,8 @@ abstract class Guya( chapterObj, chapterNum, chapterObj.getJSONArray(sortKey), - response.getString("slug") - ) + response.getString("slug"), + ), ) } response.has(sortKey) -> { @@ -374,8 +374,8 @@ abstract class Guya( chapterObj, chapterNum, response.getJSONArray(sortKey), - response.getString("slug") - ) + response.getString("slug"), + ), ) } else -> { @@ -469,8 +469,8 @@ abstract class Guya( metadata.getString("slug"), metadata.getString("folder"), pages[it].toString(), - metadata.getString("scanlator") - ) + metadata.getString("scanlator"), + ), ) } } @@ -515,8 +515,11 @@ abstract class Guya( fun getValueFromKey(key: String): String { update() // Fallback to key as value if endpoint fails - return if (!scanlatorMap[key].isNullOrEmpty()) - scanlatorMap[key].toString() else key + return if (!scanlatorMap[key].isNullOrEmpty()) { + scanlatorMap[key].toString() + } else { + key + } } fun keys(): MutableSet { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCms.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCms.kt index f04909192..cfa2d16e0 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCms.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCms.kt @@ -27,7 +27,7 @@ abstract class HeanCms( override val name: String, override val baseUrl: String, override val lang: String, - protected val apiUrl: String = baseUrl.replace("://", "://api.") + protected val apiUrl: String = baseUrl.replace("://", "://api."), ) : HttpSource() { override val supportsLatest = true @@ -56,7 +56,7 @@ abstract class HeanCms( order = "desc", orderBy = "total_views", status = "Ongoing", - type = "Comic" + type = "Comic", ) val payload = json.encodeToString(payloadObj).toRequestBody(JSON_MEDIA_TYPE) @@ -95,7 +95,7 @@ abstract class HeanCms( order = "desc", orderBy = "latest", status = "Ongoing", - type = "Comic" + type = "Comic", ) val payload = json.encodeToString(payloadObj).toRequestBody(JSON_MEDIA_TYPE) @@ -139,7 +139,7 @@ abstract class HeanCms( tagIds = filters.firstInstanceOrNull()?.state ?.filter(Genre::state) ?.map(Genre::id) - .orEmpty() + .orEmpty(), ) val payload = json.encodeToString(payloadObj).toRequestBody(JSON_MEDIA_TYPE) @@ -326,7 +326,7 @@ abstract class HeanCms( order = "desc", orderBy = "total_views", status = "", - type = "Comic" + type = "Comic", ) val payload = json.encodeToString(payloadObj).toRequestBody(JSON_MEDIA_TYPE) @@ -348,9 +348,9 @@ abstract class HeanCms( HeanCmsTitle( slug = it.slug, thumbnailFileName = it.thumbnail, - status = it.status?.toStatus() ?: SManga.UNKNOWN + status = it.status?.toStatus() ?: SManga.UNKNOWN, ) - } + }, ) } @@ -361,7 +361,7 @@ abstract class HeanCms( Filter.Header(intl.filterWarning), StatusFilter(intl.statusFilterTitle, getStatusList()), SortByFilter(intl.sortByFilterTitle, getSortProperties()), - GenreFilter(intl.genreFilterTitle, genres).takeIf { genres.isNotEmpty() } + GenreFilter(intl.genreFilterTitle, genres).takeIf { genres.isNotEmpty() }, ) return FilterList(filters) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCmsDto.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCmsDto.kt index 26578e6a0..a05a237d7 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCmsDto.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCmsDto.kt @@ -10,13 +10,13 @@ import java.text.SimpleDateFormat @Serializable data class HeanCmsQuerySearchDto( val data: List = emptyList(), - val meta: HeanCmsQuerySearchMetaDto? = null + val meta: HeanCmsQuerySearchMetaDto? = null, ) @Serializable data class HeanCmsQuerySearchMetaDto( @SerialName("current_page") val currentPage: Int, - @SerialName("last_page") val lastPage: Int + @SerialName("last_page") val lastPage: Int, ) { val hasNextPage: Boolean @@ -28,13 +28,13 @@ data class HeanCmsSearchDto( val description: String? = null, @SerialName("series_slug") val slug: String, @SerialName("series_type") val type: String, - val title: String + val title: String, ) { fun toSManga( apiUrl: String, coverPath: String, - slugMap: Map + slugMap: Map, ): SManga = SManga.create().apply { val slugOnly = slug.replace(HeanCms.TIMESTAMP_REGEX, "") val thumbnailFileName = slugMap[slugOnly]?.thumbnailFileName.orEmpty() @@ -60,7 +60,7 @@ data class HeanCmsSeriesDto( val thumbnail: String, val title: String, val tags: List? = emptyList(), - val chapters: List? = emptyList() + val chapters: List? = emptyList(), ) { fun toSManga(apiUrl: String, coverPath: String): SManga = SManga.create().apply { @@ -103,12 +103,12 @@ data class HeanCmsChapterDto( @Serializable data class HeanCmsReaderDto( - val content: HeanCmsReaderContentDto? = null + val content: HeanCmsReaderContentDto? = null, ) @Serializable data class HeanCmsReaderContentDto( - val images: List? = emptyList() + val images: List? = emptyList(), ) @Serializable @@ -118,7 +118,7 @@ data class HeanCmsQuerySearchPayloadDto( @SerialName("order_by") val orderBy: String, @SerialName("series_status") val status: String, @SerialName("series_type") val type: String, - @SerialName("tags_ids") val tagIds: List = emptyList() + @SerialName("tags_ids") val tagIds: List = emptyList(), ) @Serializable diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCmsFilters.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCmsFilters.kt index 14c3c919b..6ac91faac 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCmsFilters.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/heancms/HeanCmsFilters.kt @@ -25,7 +25,7 @@ data class SortProperty(val name: String, val value: String) { class SortByFilter(title: String, private val sortProperties: List) : Filter.Sort( title, sortProperties.map { it.name }.toTypedArray(), - Selection(1, ascending = false) + Selection(1, ascending = false), ) { val selected: String get() = sortProperties[state!!.index].value diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/hentaihand/HentaiHand.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/hentaihand/HentaiHand.kt index 45413d2fe..2115e4cfe 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/hentaihand/HentaiHand.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/hentaihand/HentaiHand.kt @@ -84,7 +84,7 @@ abstract class HentaiHand( .addQueryParameter("sort", "popularity") .addQueryParameter("order", "desc") .addQueryParameter("duration", "all") - hhLangId.forEachIndexed() { index, it -> + hhLangId.forEachIndexed { index, it -> url.addQueryParameter("languages[${-index - 1}]", it.toString()) } // if (altLangId != null) url.addQueryParameter("languages", altLangId.toString()) @@ -101,7 +101,7 @@ abstract class HentaiHand( .addQueryParameter("sort", "uploaded_at") .addQueryParameter("order", "desc") .addQueryParameter("duration", "all") - hhLangId.forEachIndexed() { index, it -> + hhLangId.forEachIndexed { index, it -> url.addQueryParameter("languages[${-index - 1}]", it.toString()) } return GET(url.toString()) @@ -121,18 +121,20 @@ abstract class HentaiHand( val idList = json.parseToJsonElement(response.body!!.string()).jsonObject["data"]!!.jsonArray.map { it.jsonObject["id"]!!.jsonPrimitive.content } - if (idList.isEmpty()) return@map null - else idList.first().toInt() + if (idList.isEmpty()) { + return@map null + } else { + idList.first().toInt() + } }.toBlocking().first() } override fun searchMangaRequest(page: Int, query: String, filters: FilterList): Request { - val url = "$baseUrl/api/comics".toHttpUrlOrNull()!!.newBuilder() .addQueryParameter("page", page.toString()) .addQueryParameter("q", query) - hhLangId.forEachIndexed() { index, it -> + hhLangId.forEachIndexed { index, it -> url.addQueryParameter("languages[${-index - 1}]", it.toString()) } @@ -150,9 +152,10 @@ abstract class HentaiHand( is LookupFilter -> { filter.state.split(",").map { it.trim() }.filter { it.isNotBlank() }.map { lookupFilterId(it, filter.uri) ?: throw Exception("No ${filter.singularName} \"$it\" was found") - }.forEachIndexed() { index, it -> - if (!(filter.uri == "languages" && hhLangId.contains(it))) + }.forEachIndexed { index, it -> + if (!(filter.uri == "languages" && hhLangId.contains(it))) { url.addQueryParameter(filter.uri + "[$index]", it.toString()) + } } } else -> {} @@ -200,7 +203,7 @@ abstract class HentaiHand( Pair("Category", try { obj["category"]!!.jsonObject["name"]!!.jsonPrimitive.content } catch (_: Exception) { null }), Pair("Language", try { obj["language"]!!.jsonObject["name"]!!.jsonPrimitive.content } catch (_: Exception) { null }), Pair("Parodies", jsonArrayToString("parodies", obj)), - Pair("Characters", jsonArrayToString("characters", obj)) + Pair("Characters", jsonArrayToString("characters", obj)), ).filter { !it.second.isNullOrEmpty() }.joinToString("\n\n") { "${it.first}: ${it.second}" } } } @@ -251,7 +254,7 @@ abstract class HentaiHand( DATE_FORMAT.parse(obj.jsonObject["uploaded_at"]!!.jsonPrimitive.content)?.time ?: 0 } chapter_number = 1f - } + }, ) } } @@ -302,8 +305,9 @@ abstract class HentaiHand( throw IOException("Failed to login, check if username and password are correct") } - if (response.body == null) + if (response.body == null) { throw IOException("Login response body is empty") + } try { // Returns access token as a string, unless unparseable return json.parseToJsonElement(response.body!!.string()).jsonObject["auth"]!!.jsonObject["access-token"]!!.jsonPrimitive.content @@ -388,7 +392,7 @@ abstract class HentaiHand( ParodiesFilter(), LanguagesFilter(), AttributesGroupFilter(getAttributePairs()), - StatusGroupFilter(getStatusPairs()) + StatusGroupFilter(getStatusPairs()), ) private fun getSortPairs() = listOf( @@ -396,12 +400,12 @@ abstract class HentaiHand( Pair("Title", "title"), Pair("Pages", "pages"), Pair("Favorites", "favorites"), - Pair("Popularity", "popularity") + Pair("Popularity", "popularity"), ) private fun getOrderPairs() = listOf( Pair("Descending", "desc"), - Pair("Ascending", "asc") + Pair("Ascending", "asc"), ) private fun getDurationPairs() = listOf( @@ -409,20 +413,20 @@ abstract class HentaiHand( Pair("This Week", "week"), Pair("This Month", "month"), Pair("This Year", "year"), - Pair("All Time", "all") + Pair("All Time", "all"), ) private fun getAttributePairs() = listOf( Pair("Translated", "translated"), Pair("Speechless", "speechless"), - Pair("Rewritten", "rewritten") + Pair("Rewritten", "rewritten"), ) private fun getStatusPairs() = listOf( Pair("Ongoing", "ongoing"), Pair("Complete", "complete"), Pair("On Hold", "onhold"), - Pair("Canceled", "canceled") + Pair("Canceled", "canceled"), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/kemono/KemonoGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/kemono/KemonoGenerator.kt index 97027f013..8fdc9c010 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/kemono/KemonoGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/kemono/KemonoGenerator.kt @@ -13,7 +13,7 @@ class KemonoGenerator : ThemeSourceGenerator { override val sources = listOf( SingleLang("Kemono", "https://kemono.party", "all", isNsfw = true), - SingleLang("Coomer", "https://coomer.party", "all", isNsfw = true) + SingleLang("Coomer", "https://coomer.party", "all", isNsfw = true), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/libgroup/LibGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/libgroup/LibGenerator.kt index 020ec92a2..9cc3e8678 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/libgroup/LibGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/libgroup/LibGenerator.kt @@ -14,7 +14,7 @@ class LibGenerator : ThemeSourceGenerator { override val sources = listOf( SingleLang("MangaLib", "https://mangalib.me", "ru", overrideVersionCode = 74), SingleLang("HentaiLib", "https://hentailib.me", "ru", isNsfw = true, overrideVersionCode = 19), - SingleLang("YaoiLib", "https://v1.yaoilib.net", "ru", isNsfw = true, overrideVersionCode = 2) + SingleLang("YaoiLib", "https://v1.yaoilib.net", "ru", isNsfw = true, overrideVersionCode = 2), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/libgroup/LibGroup.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/libgroup/LibGroup.kt index 6752d2dc8..17d4bca18 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/libgroup/LibGroup.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/libgroup/LibGroup.kt @@ -52,7 +52,7 @@ import kotlin.random.Random abstract class LibGroup( override val name: String, override val baseUrl: String, - final override val lang: String + final override val lang: String, ) : ConfigurableSource, HttpSource() { private val json: Json by injectLazy() @@ -72,8 +72,9 @@ abstract class LibGroup( val realType = possibleType[1] val image = response.body?.byteString()?.toResponseBody("image/$realType".toMediaType()) response.newBuilder().body(image).build() - } else + } else { response + } } override val client: OkHttpClient = network.cloudflareClient.newBuilder() .connectTimeout(30, TimeUnit.SECONDS) @@ -81,10 +82,12 @@ abstract class LibGroup( .rateLimit(2) .addInterceptor { chain -> val response = chain.proceed(chain.request()) - if (response.code == 419) + if (response.code == 419) { throw IOException("HTTP error ${response.code}. Проверьте сайт. Для завершения авторизации необходимо перезапустить приложение с полной остановкой.") - if (response.code == 404) + } + if (response.code == 404) { throw IOException("HTTP error ${response.code}. Проверьте сайт. Попробуйте авторизоваться через WebView и обновите список глав.") + } return@addInterceptor response } .build() @@ -180,10 +183,14 @@ abstract class LibGroup( isEng.equals("eng") && el.jsonObject["eng_name"]?.jsonPrimitive?.content.orEmpty().isNotEmpty() -> el.jsonObject["eng_name"]!!.jsonPrimitive.content else -> el.jsonObject["name"]!!.jsonPrimitive.content } - thumbnail_url = if (el.jsonObject["coverImage"] != null) el.jsonObject["coverImage"]!!.jsonPrimitive.content - else "/uploads/cover/" + slug + "/cover/" + el.jsonObject["cover"]!!.jsonPrimitive.content + "_250x350.jpg" - if (!thumbnail_url!!.contains("://")) + thumbnail_url = if (el.jsonObject["coverImage"] != null) { + el.jsonObject["coverImage"]!!.jsonPrimitive.content + } else { + "/uploads/cover/" + slug + "/cover/" + el.jsonObject["cover"]!!.jsonPrimitive.content + "_250x350.jpg" + } + if (!thumbnail_url!!.contains("://")) { thumbnail_url = baseUrl + thumbnail_url + } url = "/$slug" } @@ -241,7 +248,7 @@ abstract class LibGroup( manga.status = if (document.html().contains("paper empty section") ) { SManga.LICENSED - } else + } else { when { StatusTranslate.contains("завершен") && StatusTitle.contains("приостановлен") || StatusTranslate.contains("заморожен") || StatusTranslate.contains("заброшен") -> SManga.ON_HIATUS StatusTranslate.contains("завершен") && StatusTitle.contains("выпуск прекращён") -> SManga.CANCELLED @@ -256,11 +263,14 @@ abstract class LibGroup( else -> SManga.UNKNOWN } } + } manga.genre = category + ", " + rawAgeStop + ", " + genres.joinToString { it.trim() } - val altName = if (dataManga!!.jsonObject["altNames"]?.jsonArray.orEmpty().isNotEmpty()) + val altName = if (dataManga!!.jsonObject["altNames"]?.jsonArray.orEmpty().isNotEmpty()) { "Альтернативные названия:\n" + dataManga.jsonObject["altNames"]!!.jsonArray.joinToString(" / ") { it.jsonPrimitive.content } + "\n\n" - else "" + } else { + "" + } val mediaNameLanguage = when { isEng.equals("eng") && dataManga!!.jsonObject["rusName"]?.jsonPrimitive?.content.orEmpty().isNotEmpty() -> dataManga.jsonObject["rusName"]!!.jsonPrimitive.content + "\n" @@ -282,12 +292,14 @@ abstract class LibGroup( mangaDetailsParse(response) } } + // Chapters override fun chapterListParse(response: Response): List { val document = response.asJsoup() val rawAgeStop = document.select(".media-short-info .media-short-info__item[data-caution]").text() - if (rawAgeStop == "18+" && document.select(".m-menu__sign-in").isNotEmpty()) + if (rawAgeStop == "18+" && document.select(".m-menu__sign-in").isNotEmpty()) { throw Exception("Для просмотра 18+ контента необходима авторизация через WebView") + } val redirect = document.html() if (redirect.contains("paper empty section")) { return emptyList() @@ -340,27 +352,31 @@ abstract class LibGroup( val teamId = branch.jsonObject["id"]!!.jsonPrimitive.int val teams = branch.jsonObject["teams"]!!.jsonArray val isActive = teams.filter { it.jsonObject["is_active"]?.jsonPrimitive?.intOrNull == 1 } - val teamsBranch = if (isActive.size == 1) + val teamsBranch = if (isActive.size == 1) { isActive[0].jsonObject["name"]?.jsonPrimitive?.contentOrNull - else if (teams.isNotEmpty() && isActive.isEmpty()) + } else if (teams.isNotEmpty() && isActive.isEmpty()) { teams[0].jsonObject["name"]?.jsonPrimitive?.contentOrNull - else "Неизвестный" + } else { + "Неизвестный" + } chapters = chaptersList ?.filter { it.jsonObject["branch_id"]?.jsonPrimitive?.intOrNull == teamId && it.jsonObject["status"]?.jsonPrimitive?.intOrNull != 2 } ?.map { chapterFromElement(it, sortingList, slug, userId, teamId, branches) } when (sortingList) { "ms_mixing" -> { chapters?.let { - if ((tempChaptersList.size < it.size) && !groupTranslates.contains(teamsBranch.toString())) + if ((tempChaptersList.size < it.size) && !groupTranslates.contains(teamsBranch.toString())) { tempChaptersList.addAll(0, it) - else + } else { tempChaptersList.addAll(it) + } } chapters = tempChaptersList.distinctBy { volume.find(it.url)?.value + "--" + it.chapter_number }.sortedWith(compareBy({ -it.chapter_number }, { volume.find(it.url)?.value })) } "ms_combining" -> { - if (!groupTranslates.contains(teamsBranch.toString())) + if (!groupTranslates.contains(teamsBranch.toString())) { chapters?.let { tempChaptersList.addAll(it) } + } chapters = tempChaptersList } } @@ -404,7 +420,11 @@ abstract class LibGroup( val scanlatorId = chapterItem.jsonObject["chapter_scanlator_id"]!!.jsonPrimitive.int if ((scanlatorId == team.jsonObject["id"]!!.jsonPrimitive.int) || (scanlatorId == 0 && team["is_active"]!!.jsonPrimitive.int == 1) - ) return team["name"]!!.jsonPrimitive.content else scanlatorData = branch["teams"]!!.jsonArray[0].jsonObject["name"]!!.jsonPrimitive.content + ) { + return team["name"]!!.jsonPrimitive.content + } else { + scanlatorData = branch["teams"]!!.jsonArray[0].jsonObject["name"]!!.jsonPrimitive.content + } } } } @@ -585,13 +605,13 @@ abstract class LibGroup( GenreList(getGenreList()), StatusList(getStatusList()), StatusTitleList(getStatusTitleList()), - MyList(getMyList()) + MyList(getMyList()), ) private class OrderBy : Filter.Sort( "Сортировка", arrayOf("Рейтинг", "Имя", "Просмотры", "Дате добавления", "Дате обновления", "Кол-во глав"), - Selection(2, false) + Selection(2, false), ) private fun getCategoryList() = listOf( @@ -600,7 +620,7 @@ abstract class LibGroup( CheckFilter("Манхва", "5"), CheckFilter("Маньхуа", "6"), CheckFilter("Руманга", "8"), - CheckFilter("Комикс западный", "9") + CheckFilter("Комикс западный", "9"), ) private fun getFormatList() = listOf( @@ -609,14 +629,14 @@ abstract class LibGroup( SearchFilter("Додзинси", "3"), SearchFilter("Сингл", "4"), SearchFilter("В цвете", "5"), - SearchFilter("Веб", "6") + SearchFilter("Веб", "6"), ) private fun getStatusList() = listOf( CheckFilter("Продолжается", "1"), CheckFilter("Завершен", "2"), CheckFilter("Заморожен", "3"), - CheckFilter("Заброшен", "4") + CheckFilter("Заброшен", "4"), ) private fun getStatusTitleList() = listOf( @@ -671,7 +691,7 @@ abstract class LibGroup( SearchFilter("эротика", "71"), SearchFilter("этти", "72"), SearchFilter("юри", "73"), - SearchFilter("яой", "74") + SearchFilter("яой", "74"), ) private fun getMyList() = listOf( @@ -679,7 +699,7 @@ abstract class LibGroup( SearchFilter("В планах", "2"), SearchFilter("Брошено", "3"), SearchFilter("Прочитано", "4"), - SearchFilter("Любимые", "5") + SearchFilter("Любимые", "5"), ) companion object { const val PREFIX_SLUG_SEARCH = "slug:" @@ -722,7 +742,8 @@ abstract class LibGroup( key = SORTING_PREF title = SORTING_PREF_Title entries = arrayOf( - "Полный список (без повторных переводов)", "Все переводы (друг за другом)" + "Полный список (без повторных переводов)", + "Все переводы (друг за другом)", ) entryValues = arrayOf("ms_mixing", "ms_combining") summary = "%s" diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/Madara.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/Madara.kt index 7cf6aeee3..9d96aad6d 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/Madara.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/Madara.kt @@ -48,7 +48,7 @@ abstract class Madara( override val name: String, override val baseUrl: String, final override val lang: String, - private val dateFormat: SimpleDateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.US) + private val dateFormat: SimpleDateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.US), ) : ParsedHttpSource(), ConfigurableSource { private val preferences: SharedPreferences by lazy { @@ -227,7 +227,7 @@ abstract class Madara( "$baseUrl/wp-admin/admin-ajax.php", formHeaders, formBuilder(page, true).build(), - CacheControl.FORCE_NETWORK + CacheControl.FORCE_NETWORK, ) } @@ -296,9 +296,11 @@ abstract class Madara( if (!response.isSuccessful) { response.close() // Error message for exceeding last page - if (response.code == 404) + if (response.code == 404) { error("Already on the Last Page!") - else throw Exception("HTTP error ${response.code}") + } else { + throw Exception("HTTP error ${response.code}") + } } } .map { response -> @@ -466,7 +468,7 @@ abstract class Madara( add("vars[meta_query][$metaQueryIdx][key]", "manga_adult_content") add( "vars[meta_query][$metaQueryIdx][compare]", - if (filter.state == 1) "not exists" else "exists" + if (filter.state == 1) "not exists" else "exists", ) metaQueryIdx++ @@ -502,7 +504,7 @@ abstract class Madara( "$baseUrl/wp-admin/admin-ajax.php", searchHeaders, formBodyBuilder.build(), - CacheControl.FORCE_NETWORK + CacheControl.FORCE_NETWORK, ) } @@ -532,7 +534,10 @@ abstract class Madara( } protected val statusFilterOptionsValues: Array = arrayOf( - "end", "on-going", "canceled", "on-hold" + "end", + "on-going", + "canceled", + "on-hold", ) protected open val orderByFilterTitle: String = when (lang) { @@ -542,17 +547,33 @@ abstract class Madara( protected open val orderByFilterOptions: Array = when (lang) { "pt-BR" -> arrayOf( - "Relevância", "Recentes", "A-Z", "Avaliação", - "Tendência", "Visualizações", "Novos" + "Relevância", + "Recentes", + "A-Z", + "Avaliação", + "Tendência", + "Visualizações", + "Novos", ) else -> arrayOf( - "Relevance", "Latest", "A-Z", "Rating", - "Trending", "Most Views", "New" + "Relevance", + "Latest", + "A-Z", + "Rating", + "Trending", + "Most Views", + "New", ) } protected val orderByFilterOptionsValues: Array = arrayOf( - "", "latest", "alphabet", "rating", "trending", "views", "new-manga" + "", + "latest", + "alphabet", + "rating", + "trending", + "views", + "new-manga", ) protected open val genreConditionFilterTitle: String = when (lang) { @@ -606,12 +627,12 @@ abstract class Madara( protected class GenreConditionFilter(title: String, options: Array) : UriPartFilter( title, - options.zip(arrayOf("", "1")).toTypedArray() + options.zip(arrayOf("", "1")).toTypedArray(), ) protected class AdultContentFilter(title: String, options: Array) : UriPartFilter( title, - options.zip(arrayOf("", "0", "1")).toTypedArray() + options.zip(arrayOf("", "0", "1")).toTypedArray(), ) protected class GenreList(title: String, genres: List) : Filter.Group(title, genres) @@ -628,9 +649,9 @@ abstract class Madara( OrderByFilter( orderByFilterTitle, orderByFilterOptions.zip(orderByFilterOptionsValues), - if (useLoadMoreSearch) 5 else 0 + if (useLoadMoreSearch) 5 else 0, ), - AdultContentFilter(adultContentFilterTitle, adultContentFilterOptions) + AdultContentFilter(adultContentFilterTitle, adultContentFilterOptions), ) if (useLoadMoreSearch) { @@ -642,12 +663,12 @@ abstract class Madara( Filter.Separator(), Filter.Header(genreFilterHeader), GenreConditionFilter(genreConditionFilterTitle, genreConditionFilterOptions), - GenreList(genreFilterTitle, genresList) + GenreList(genreFilterTitle, genresList), ) } else if (fetchGenres) { filters += listOf( Filter.Separator(), - Filter.Header(genresMissingWarning) + Filter.Header(genresMissingWarning), ) } @@ -696,22 +717,28 @@ abstract class Madara( // Manga Details Parse protected val completedStatusList: Array = arrayOf( - "Completed", "Completo", "Concluído", "Concluido", "Terminé", "Hoàn Thành", "مكتملة", - "مكتمل" + "Completed", + "Completo", + "Concluído", + "Concluido", + "Terminé", + "Hoàn Thành", + "مكتملة", + "مكتمل", ) protected val ongoingStatusList: Array = arrayOf( "OnGoing", "Продолжается", "Updating", "Em Lançamento", "Em lançamento", "Em andamento", "Em Andamento", "En cours", "Ativo", "Lançando", "Đang Tiến Hành", "Devam Ediyor", - "Devam ediyor", "In Corso", "In Arrivo", "مستمرة", "مستمر", "En Curso" + "Devam ediyor", "In Corso", "In Arrivo", "مستمرة", "مستمر", "En Curso", ) protected val hiatusStatusList: Array = arrayOf( - "On Hold" + "On Hold", ) protected val canceledStatusList: Array = arrayOf( - "Canceled" + "Canceled", ) override fun mangaDetailsParse(document: Document): SManga { @@ -880,8 +907,11 @@ abstract class Madara( val mangaUrl = document.location().removeSuffix("/") val mangaId = chaptersWrapper.attr("data-id") - var xhrRequest = if (useNewChapterEndpoint || oldChapterEndpointDisabled) - xhrChaptersRequest(mangaUrl) else oldXhrChaptersRequest(mangaId) + var xhrRequest = if (useNewChapterEndpoint || oldChapterEndpointDisabled) { + xhrChaptersRequest(mangaUrl) + } else { + oldXhrChaptersRequest(mangaId) + } var xhrResponse = client.newCall(xhrRequest).execute() // Newer Madara versions throws HTTP 400 when using the old endpoint. @@ -1025,7 +1055,7 @@ abstract class Madara( document.location(), element.select("img").first()?.let { it.absUrl(if (it.hasAttr("data-src")) "data-src" else "src") - } + }, ) } } @@ -1127,7 +1157,7 @@ abstract class Madara( .map { li -> Genre( li.selectFirst("label").text(), - li.selectFirst("input[type=checkbox]").`val`() + li.selectFirst("input[type=checkbox]").`val`(), ) } } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/MadaraUrlActivity.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/MadaraUrlActivity.kt index 4b3c9a0bd..788e2d4a4 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/MadaraUrlActivity.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madara/MadaraUrlActivity.kt @@ -13,7 +13,6 @@ class MadaraUrlActivity : Activity() { val pathSegments = intent?.data?.pathSegments if (pathSegments != null && pathSegments.size >= 2) { - val mainIntent = Intent().apply { action = "eu.kanade.tachiyomi.SEARCH" putExtra("query", "${getSLUG(pathSegments)}") diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madtheme/MadTheme.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madtheme/MadTheme.kt index ca72c2d46..916d54a87 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madtheme/MadTheme.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/madtheme/MadTheme.kt @@ -34,7 +34,7 @@ abstract class MadTheme( override val name: String, override val baseUrl: String, override val lang: String, - private val dateFormat: SimpleDateFormat = SimpleDateFormat("MMM dd, yyy", Locale.US) + private val dateFormat: SimpleDateFormat = SimpleDateFormat("MMM dd, yyy", Locale.US), ) : ParsedHttpSource() { override val supportsLatest = true @@ -312,7 +312,7 @@ abstract class MadTheme( Pair("All", "all"), Pair("Ongoing", "ongoing"), Pair("Completed", "completed"), - ) + ), ) class OrderFilter(state: Int = 0) : UriPartFilter( @@ -324,13 +324,13 @@ abstract class MadTheme( Pair("Name A-Z", "name"), Pair("Rating", "rating"), ), - state + state, ) open class UriPartFilter( displayName: String, private val vals: Array>, - state: Int = 0 + state: Int = 0, ) : Filter.Select(displayName, vals.map { it.first }.toTypedArray(), state) { fun toUriPart() = vals[state].second diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabox/MangaBox.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabox/MangaBox.kt index 3a56cf086..8b4d4c770 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabox/MangaBox.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabox/MangaBox.kt @@ -27,7 +27,7 @@ abstract class MangaBox( override val name: String, override val baseUrl: String, override val lang: String, - private val dateformat: SimpleDateFormat = SimpleDateFormat("MMM-dd-yy", Locale.ENGLISH) + private val dateformat: SimpleDateFormat = SimpleDateFormat("MMM-dd-yy", Locale.ENGLISH), ) : ParsedHttpSource() { override val supportsLatest = true @@ -137,8 +137,9 @@ abstract class MangaBox( } private fun checkForRedirectMessage(document: Document) { - if (document.select("body").text().startsWith("REDIRECT :")) + if (document.select("body").text().startsWith("REDIRECT :")) { throw Exception("Source URL has changed") + } } override fun mangaDetailsParse(document: Document): SManga { @@ -292,7 +293,7 @@ abstract class MangaBox( KeywordFilter(getKeywordFilters()), SortFilter(getSortFilters()), StatusFilter(getStatusFilters()), - AdvGenreFilter(getAdvancedGenreFilters()) + AdvGenreFilter(getAdvancedGenreFilters()), ) } else { FilterList( @@ -300,7 +301,7 @@ abstract class MangaBox( Filter.Separator(), SortFilter(getSortFilters()), StatusFilter(getStatusFilters()), - GenreFilter(getGenreFilters()) + GenreFilter(getGenreFilters()), ) } @@ -318,20 +319,20 @@ abstract class MangaBox( Pair(null, "Everything"), Pair("title", "Title"), Pair("alternative", "Alt title"), - Pair("author", "Author") + Pair("author", "Author"), ) private fun getSortFilters(): Array> = arrayOf( Pair("latest", "Latest"), Pair("newest", "Newest"), - Pair("topview", "Top read") + Pair("topview", "Top read"), ) open fun getStatusFilters(): Array> = arrayOf( Pair("all", "ALL"), Pair("completed", "Completed"), Pair("ongoing", "Ongoing"), - Pair("drop", "Dropped") + Pair("drop", "Dropped"), ) open fun getGenreFilters(): Array> = arrayOf( @@ -375,7 +376,7 @@ abstract class MangaBox( Pair("39", "Tragedy"), Pair("40", "Webtoons"), Pair("41", "Yaoi"), - Pair("42", "Yuri") + Pair("42", "Yuri"), ) // To be overridden if using tri-state genres diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabz/MangabzTheme.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabz/MangabzTheme.kt index acb422412..d030a8d2d 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabz/MangabzTheme.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangabz/MangabzTheme.kt @@ -19,7 +19,7 @@ import org.jsoup.select.Evaluator abstract class MangabzTheme( override val name: String, override val baseUrl: String, - override val lang: String = "zh" + override val lang: String = "zh", ) : HttpSource() { override val supportsLatest = true diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangacatalog/MangaCatalog.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangacatalog/MangaCatalog.kt index dbaecb3f4..d1cbd0d4c 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangacatalog/MangaCatalog.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangacatalog/MangaCatalog.kt @@ -18,10 +18,10 @@ import rx.Observable abstract class MangaCatalog( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { open val sourceList = listOf( - Pair("$name", "$baseUrl") + Pair("$name", "$baseUrl"), ).sortedBy { it.first }.distinctBy { it.second } // Info diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventure.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventure.kt index 103160a73..6423810c3 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventure.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventure.kt @@ -20,7 +20,7 @@ import eu.kanade.tachiyomi.source.model.Page as SPage abstract class MangAdventure( override val name: String, override val baseUrl: String, - override val lang: String = "en" + override val lang: String = "en", ) : HttpSource() { /** The site's manga categories. */ protected open val categories = DEFAULT_CATEGORIES @@ -30,7 +30,10 @@ abstract class MangAdventure( /** The site's sort order labels that correspond to [SortOrder.values]. */ protected open val orders = arrayOf( - "Title", "Views", "Latest upload", "Chapter count" + "Title", + "Views", + "Latest upload", + "Chapter count", ) /** A user agent representing Tachiyomi. */ @@ -130,7 +133,7 @@ abstract class MangAdventure( Artist(), SortOrder(orders), Status(statuses), - CategoryList(categories) + CategoryList(categories), ) /** Decodes the JSON response as an object. */ @@ -146,8 +149,9 @@ abstract class MangAdventure( description = buildString { series.description?.let(::append) series.aliases.let { - if (!it.isNullOrEmpty()) + if (!it.isNullOrEmpty()) { it.joinTo(this, "\n", "\n\nAlternative titles:\n") + } } } author = series.authors?.joinToString() @@ -155,10 +159,12 @@ abstract class MangAdventure( genre = series.categories?.joinToString() status = if (series.licensed == true) { SManga.LICENSED - } else when (series.completed) { - true -> SManga.COMPLETED - false -> SManga.ONGOING - null -> SManga.UNKNOWN + } else { + when (series.completed) { + true -> SManga.COMPLETED + false -> SManga.ONGOING + null -> SManga.UNKNOWN + } } } @@ -197,7 +203,7 @@ abstract class MangAdventure( "Supernatural", "Tragedy", "Yaoi", - "Yuri" + "Yuri", ) /** Query to search by manga slug. */ diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventureAPI.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventureAPI.kt index 4aeed52a9..ccb7ed098 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventureAPI.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventureAPI.kt @@ -3,14 +3,14 @@ package eu.kanade.tachiyomi.multisrc.mangadventure /** Generic results wrapper schema. */ @kotlinx.serialization.Serializable internal class Results( - private val results: List + private val results: List, ) : Iterable by results /** Generic paginator schema. */ @kotlinx.serialization.Serializable internal class Paginator( val last: Boolean, - private val results: List + private val results: List, ) : Iterable by results /** Page model schema. */ @@ -19,7 +19,7 @@ internal data class Page( private val id: Int, val image: String, val number: Int, - val url: String + val url: String, ) { override fun equals(other: Any?) = this === other || other is Page && id == other.id @@ -38,7 +38,7 @@ internal data class Chapter( val final: Boolean, val series: String, val groups: List, - val full_title: String + val full_title: String, ) { override fun equals(other: Any?) = this === other || other is Chapter && id == other.id @@ -58,7 +58,7 @@ internal data class Series( val aliases: List? = null, val authors: List? = null, val artists: List? = null, - val categories: List? = null + val categories: List? = null, ) { override fun equals(other: Any?) = this === other || other is Series && slug == other.slug diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventureFilters.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventureFilters.kt index a96b2119f..d1321fff5 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventureFilters.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangadventure/MangAdventureFilters.kt @@ -28,7 +28,7 @@ internal class Artist : Filter.Text("Artist"), UriFilter { * @param labels The site's sort order labels. */ internal class SortOrder( - private val labels: Array + private val labels: Array, ) : Filter.Sort("Sort", labels, null), UriFilter { override val param = "sort" @@ -41,7 +41,10 @@ internal class SortOrder( companion object { /** The available sort order values. */ private val sorts = arrayOf( - "title", "views", "latest_upload", "chapter_count" + "title", + "views", + "latest_upload", + "chapter_count", ) } } @@ -52,7 +55,7 @@ internal class SortOrder( * @param statuses The site's status names. */ internal class Status( - statuses: Array + statuses: Array, ) : Filter.Select("Status", statuses), UriFilter { override val param = "status" @@ -72,7 +75,7 @@ internal class Category(name: String) : Filter.TriState(name) * @param categories The site's manga categories. */ internal class CategoryList( - categories: List + categories: List, ) : Filter.Group("Categories", categories.map(::Category)), UriFilter { override val param = "categories" diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangahub/MangaHub.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangahub/MangaHub.kt index aed3d2df1..b2919ff96 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangahub/MangaHub.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangahub/MangaHub.kt @@ -31,7 +31,7 @@ abstract class MangaHub( override val name: String, override val baseUrl: String, override val lang: String, - private val dateFormat: SimpleDateFormat = SimpleDateFormat("MM-dd-yyyy", Locale.US) + private val dateFormat: SimpleDateFormat = SimpleDateFormat("MM-dd-yyyy", Locale.US), ) : ParsedHttpSource() { override val supportsLatest = true @@ -190,8 +190,11 @@ abstract class MangaHub( document.select("h1 small").firstOrNull()?.ownText()?.let { alternativeName -> if (alternativeName.isNotBlank()) { manga.description = manga.description.orEmpty().let { - if (it.isBlank()) "Alternative Name: $alternativeName" - else "$it\n\nAlternative Name: $alternativeName" + if (it.isBlank()) { + "Alternative Name: $alternativeName" + } else { + "$it\n\nAlternative Name: $alternativeName" + } } } } @@ -346,7 +349,7 @@ abstract class MangaHub( override fun getFilterList() = FilterList( OrderBy(orderBy), - GenreList(genres) + GenreList(genres), ) private val orderBy = arrayOf( @@ -354,7 +357,7 @@ abstract class MangaHub( Order("Updates", "LATEST"), Order("A-Z", "ALPHABET"), Order("New", "NEW"), - Order("Completed", "COMPLETED") + Order("Completed", "COMPLETED"), ) private val genres = arrayOf( @@ -421,7 +424,7 @@ abstract class MangaHub( Genre("Webtoon", "webtoon"), Genre("Webtoons", "webtoons"), Genre("Wuxia", "wuxia"), - Genre("Yuri", "yuri") + Genre("Yuri", "yuri"), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainac.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainac.kt index e2014432a..aabb5ddc3 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainac.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainac.kt @@ -121,18 +121,19 @@ abstract class MangaMainac( val document = response.asJsoup() val chapterList = document.select(chapterListSelector()).map { chapterFromElement(it) } - return if (hasCountdown(chapterList[0])) + return if (hasCountdown(chapterList[0])) { chapterList.subList(1, chapterList.size) - else + } else { chapterList + } } private fun hasCountdown(chapter: SChapter): Boolean { val document = client.newCall( GET( baseUrl + chapter.url, - headersBuilder().build() - ) + headersBuilder().build(), + ), ).execute().asJsoup() return document diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainacGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainacGenerator.kt index 36b3cfa7f..c32e372be 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainacGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangamainac/MangaMainacGenerator.kt @@ -20,7 +20,7 @@ class MangaMainacGenerator : ThemeSourceGenerator { SingleLang("Read Black Clover Manga", "https://w6.blackclovermanga2.com/", "en", overrideVersionCode = 1), SingleLang("Read Shingeki no Kyojin Manga", "https://readshingekinokyojin.com/", "en"), SingleLang("Read Nanatsu no Taizai Manga", "https://w2.readnanatsutaizai.net/", "en", overrideVersionCode = 1), - SingleLang("Read Rent a Girlfriend Manga", "https://kanojo-okarishimasu.com/", "en") + SingleLang("Read Rent a Girlfriend Manga", "https://kanojo-okarishimasu.com/", "en"), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaraw/ImageListParser.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaraw/ImageListParser.kt index 79f8b4504..742928450 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaraw/ImageListParser.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaraw/ImageListParser.kt @@ -6,7 +6,7 @@ class ImageListParser( html: String, private val position: Int, private val keys: String = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", - private val pattern: String = """'BYFxAcGcC4.*?'""" + private val pattern: String = """'BYFxAcGcC4.*?'""", ) { private val code: String diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaraw/MangaRawTheme.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaraw/MangaRawTheme.kt index 66129cf4a..c7e89dc4d 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaraw/MangaRawTheme.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaraw/MangaRawTheme.kt @@ -12,7 +12,7 @@ import org.jsoup.select.Evaluator abstract class MangaRawTheme( override val name: String, override val baseUrl: String, - override val lang: String = "ja" + override val lang: String = "ja", ) : ParsedHttpSource() { override fun headersBuilder() = super.headersBuilder().add("Referer", "$baseUrl/") diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSar.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSar.kt index 442337619..2c0bd4b93 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSar.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSar.kt @@ -35,7 +35,7 @@ import java.util.concurrent.TimeUnit abstract class MangaSar( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : HttpSource() { override val supportsLatest = true diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSarDto.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSarDto.kt index 5d540aa3a..432f64be2 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSarDto.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSarDto.kt @@ -9,28 +9,28 @@ import kotlinx.serialization.json.JsonPrimitive data class MangaSarLatestDto( val page: String, @JsonNames("lancamentos") val releases: List = emptyList(), - @SerialName("total_page") val totalPage: Int? = 0 + @SerialName("total_page") val totalPage: Int? = 0, ) @Serializable data class MangaSarReleaseDto( val image: String, val link: String, - val name: String + val name: String, ) @Serializable data class MangaSarTitleDto( @SerialName("img") val image: String, val title: String, - val url: String + val url: String, ) @Serializable data class MangaSarPaginatedChaptersDto( val chapters: List? = emptyList(), @SerialName("pagina") val page: Int? = -1, - @SerialName("total_pags") val totalPages: Int? = -1 + @SerialName("total_pags") val totalPages: Int? = -1, ) @Serializable @@ -38,15 +38,15 @@ data class MangaSarChapterDto( @SerialName("date_created") val dateCreated: String, val link: String, @SerialName("chapter_name") val name: JsonPrimitive, - val number: JsonPrimitive + val number: JsonPrimitive, ) @Serializable data class MangaSarReaderDto( - val images: List = emptyList() + val images: List = emptyList(), ) @Serializable data class MangaSarPageDto( - val url: String + val url: String, ) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSarGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSarGenerator.kt index ed0351563..130d22658 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSarGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasar/MangaSarGenerator.kt @@ -15,7 +15,7 @@ class MangaSarGenerator : ThemeSourceGenerator { SingleLang("Fire Mangás", "https://firemangas.com", "pt-BR", className = "FireMangas"), SingleLang("Mangazim", "https://mangazim.com", "pt-BR"), SingleLang("MangásUp", "https://mangasup.net", "pt-BR", className = "MangasUp"), - SingleLang("Seemangas", "https://seemangas.com", "pt-BR", isNsfw = true) + SingleLang("Seemangas", "https://seemangas.com", "pt-BR", isNsfw = true), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangathemesia/MangaThemesia.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangathemesia/MangaThemesia.kt index d30acd7b8..985748e68 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangathemesia/MangaThemesia.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangathemesia/MangaThemesia.kt @@ -36,7 +36,7 @@ abstract class MangaThemesia( override val baseUrl: String, override val lang: String, val mangaUrlDirectory: String = "/manga", - val dateFormat: SimpleDateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.US) + val dateFormat: SimpleDateFormat = SimpleDateFormat("MMMM dd, yyyy", Locale.US), ) : ParsedHttpSource() { protected open val json: Json by injectLazy() @@ -71,7 +71,7 @@ abstract class MangaThemesia( return fetchMangaDetails( SManga.create() - .apply { this.url = "$mangaUrlDirectory/$mangaPath/" } + .apply { this.url = "$mangaUrlDirectory/$mangaPath/" }, ) .map { // Isn't set in returned manga @@ -172,8 +172,11 @@ abstract class MangaThemesia( seriesDetails.selectFirst(seriesTypeSelector)?.ownText().takeIf { it.isNullOrBlank().not() }?.let { genres.add(it) } genre = genres.map { genre -> genre.lowercase(Locale.forLanguageTag(lang)).replaceFirstChar { char -> - if (char.isLowerCase()) char.titlecase(Locale.forLanguageTag(lang)) - else char.toString() + if (char.isLowerCase()) { + char.titlecase(Locale.forLanguageTag(lang)) + } else { + char.toString() + } } } .joinToString { it.trim() } @@ -313,11 +316,11 @@ abstract class MangaThemesia( open class SelectFilter( displayName: String, val vals: Array>, - defaultValue: String? = null + defaultValue: String? = null, ) : Filter.Select( displayName, vals.map { it.first }.toTypedArray(), - vals.indexOfFirst { it.second == defaultValue }.takeIf { it != -1 } ?: 0 + vals.indexOfFirst { it.second == defaultValue }.takeIf { it != -1 } ?: 0, ) { fun selectedValue() = vals[state].second } @@ -329,8 +332,8 @@ abstract class MangaThemesia( Pair("Ongoing", "ongoing"), Pair("Completed", "completed"), Pair("Hiatus", "hiatus"), - Pair("Dropped", "dropped") - ) + Pair("Dropped", "dropped"), + ), ) protected class TypeFilter : SelectFilter( @@ -340,8 +343,8 @@ abstract class MangaThemesia( Pair("Manga", "Manga"), Pair("Manhwa", "Manhwa"), Pair("Manhua", "Manhua"), - Pair("Comic", "Comic") - ) + Pair("Comic", "Comic"), + ), ) protected class OrderByFilter(defaultOrder: String? = null) : SelectFilter( @@ -352,23 +355,23 @@ abstract class MangaThemesia( Pair("Z-A", "titlereverse"), Pair("Latest Update", "update"), Pair("Latest Added", "latest"), - Pair("Popular", "popular") + Pair("Popular", "popular"), ), - defaultOrder + defaultOrder, ) protected class ProjectFilter : SelectFilter( "Filter Project", arrayOf( Pair("Show all manga", ""), - Pair("Show only project manga", "project-filter-on") - ) + Pair("Show only project manga", "project-filter-on"), + ), ) protected class Genre( name: String, val value: String, - state: Int = STATE_IGNORE + state: Int = STATE_IGNORE, ) : Filter.TriState(name, state) protected class GenreListFilter(genres: List) : Filter.Group("Genre", genres) @@ -401,7 +404,7 @@ abstract class MangaThemesia( Filter.Header("NOTE: Can't be used with other filter!"), Filter.Header("$name Project List page"), ProjectFilter(), - ) + ), ) } return FilterList(filters) @@ -450,7 +453,7 @@ abstract class MangaThemesia( return document.selectFirst("ul.genrez")?.select("li")?.map { li -> Genre( li.selectFirst("label").text(), - li.selectFirst("input[type=checkbox]").attr("value") + li.selectFirst("input[type=checkbox]").attr("value"), ) } } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangathemesia/MangaThemesiaUrlActivity.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangathemesia/MangaThemesiaUrlActivity.kt index 6999ab7ae..a24ddc9b9 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangathemesia/MangaThemesiaUrlActivity.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangathemesia/MangaThemesiaUrlActivity.kt @@ -14,7 +14,6 @@ class MangaThemesiaUrlActivity : Activity() { val pathSegments = intent?.data?.pathSegments if (pathSegments != null && pathSegments.size >= 1) { - val mainIntent = Intent().apply { action = "eu.kanade.tachiyomi.SEARCH" putExtra("query", "${MangaThemesia.URL_SEARCH_PREFIX}${intent?.data?.toString()}") diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaworld/MangaWorld.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaworld/MangaWorld.kt index 9c1e7ea72..8bb5a1528 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaworld/MangaWorld.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangaworld/MangaWorld.kt @@ -24,7 +24,7 @@ import java.util.Locale abstract class MangaWorld( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = true @@ -105,8 +105,9 @@ abstract class MangaWorld( override fun mangaDetailsParse(document: Document): SManga { val infoElement = document.select("div.comic-info") - if (infoElement.isEmpty()) + if (infoElement.isEmpty()) { throw Exception("Page not found") + } val manga = SManga.create() manga.author = infoElement.select("a[href*=/archive?author=]").first()?.text() @@ -115,8 +116,9 @@ abstract class MangaWorld( var description = document.select("div#noidungm").text() val otherTitle = document.select("div.meta-data > div").first()?.text() - if (!otherTitle.isNullOrBlank() && otherTitle.contains("Titoli alternativi")) + if (!otherTitle.isNullOrBlank() && otherTitle.contains("Titoli alternativi")) { description += "\n\n$otherTitle" + } manga.description = description.trim() manga.genre = infoElement.select("div.meta-data a.badge").joinToString(", ") { @@ -130,8 +132,9 @@ abstract class MangaWorld( } protected fun parseStatus(element: String?): Int { - if (element.isNullOrEmpty()) + if (element.isNullOrEmpty()) { return SManga.UNKNOWN + } return when (element.lowercase()) { "in corso" -> SManga.ONGOING "finito" -> SManga.COMPLETED @@ -157,14 +160,16 @@ abstract class MangaWorld( chapter.date_upload = date val number = parseChapterNumber(name) - if (number != null) + if (number != null) { chapter.chapter_number = number + } return chapter } protected fun fixChapterUrl(url: String?): String { - if (url.isNullOrEmpty()) + if (url.isNullOrEmpty()) { return "" + } val params = url.split("?").let { if (it.size > 1) it[1] else "" } return when { params.contains("style=list") -> url @@ -176,8 +181,9 @@ abstract class MangaWorld( } protected fun parseChapterDate(string: String?): Long { - if (string == null) + if (string == null) { return 0L + } return runCatching { DATE_FORMATTER.parse(string)?.time }.getOrNull() ?: runCatching { DATE_FORMATTER_2.parse(string)?.time }.getOrNull() ?: 0L } @@ -210,7 +216,7 @@ abstract class MangaWorld( SortBy(), StatusList(getStatusList()), GenreList(getGenreList()), - MTypeList(getTypesList()) + MTypeList(getTypesList()), ) private class SortBy : UriPartFilter( @@ -222,8 +228,8 @@ abstract class MangaWorld( Pair("Più recenti", "newest"), Pair("Meno recenti", "oldest"), Pair("A-Z", "a-z"), - Pair("Z-A", "z-a") - ) + Pair("Z-A", "z-a"), + ), ) private class TextField(name: String, val key: String) : Filter.Text(name) @@ -273,7 +279,7 @@ abstract class MangaWorld( Genre("Storico", "storico"), Genre("Tragico", "tragico"), Genre("Yaoi", "yaoi"), - Genre("Yuri", "yuri") + Genre("Yuri", "yuri"), ) protected fun getTypesList() = listOf( MType("Manga", "manga"), @@ -281,14 +287,14 @@ abstract class MangaWorld( MType("Manhwa", "manhwa"), MType("Oneshot", "oneshot"), MType("Thai", "thai"), - MType("Vietnamita", "vietnamese") + MType("Vietnamita", "vietnamese"), ) protected fun getStatusList() = listOf( Status("In corso", "ongoing"), Status("Finito", "completed"), Status("Droppato", "dropped"), Status("In pausa", "paused"), - Status("Cancellato", "canceled") + Status("Cancellato", "canceled"), ) private open class UriPartFilter(displayName: String, val vals: Array>) : diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mccms/MCCMS.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mccms/MCCMS.kt index 4e3c1b7f7..8497e8bdb 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mccms/MCCMS.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mccms/MCCMS.kt @@ -29,7 +29,7 @@ open class MCCMS( override val name: String, override val baseUrl: String, override val lang: String = "zh", - hasCategoryPage: Boolean = false + hasCategoryPage: Boolean = false, ) : HttpSource() { override val supportsLatest = true diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mccms/MCCMSGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mccms/MCCMSGenerator.kt index 9c8ab8a53..88b2aad20 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mccms/MCCMSGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mccms/MCCMSGenerator.kt @@ -9,49 +9,98 @@ class MCCMSGenerator : ThemeSourceGenerator { override val baseVersionCode = 5 override val sources = listOf( SingleLang( - name = "Haoman6", baseUrl = "https://www.haoman6.com", lang = "zh", - className = "Haoman6", sourceName = "好漫6", overrideVersionCode = 3 + name = "Haoman6", + baseUrl = "https://www.haoman6.com", + lang = "zh", + className = "Haoman6", + sourceName = "好漫6", + overrideVersionCode = 3, ), SingleLang( // previously: app2.haoman6.com, app2.haomanwu.com - name = "Haomanwu", baseUrl = "https://move.bookcomic.org", lang = "zh", - className = "Haomanwu", sourceName = "好漫屋", overrideVersionCode = 3 + name = "Haomanwu", + baseUrl = "https://move.bookcomic.org", + lang = "zh", + className = "Haomanwu", + sourceName = "好漫屋", + overrideVersionCode = 3, ), SingleLang( // same as: www.haoman6.cc - name = "Haoman6 (g-lens)", baseUrl = "https://www.g-lens.com", lang = "zh", - className = "Haoman6_glens", sourceName = "好漫6 (g-lens)", overrideVersionCode = 0 + name = "Haoman6 (g-lens)", + baseUrl = "https://www.g-lens.com", + lang = "zh", + className = "Haoman6glens", + sourceName = "好漫6 (g-lens)", + overrideVersionCode = 0, ), SingleLang( // same as: www.haoman8.com - name = "Haoman8", baseUrl = "https://caiji.haoman8.com", lang = "zh", - className = "Haoman8", sourceName = "好漫8", overrideVersionCode = 0 + name = "Haoman8", + baseUrl = "https://caiji.haoman8.com", + lang = "zh", + className = "Haoman8", + sourceName = "好漫8", + overrideVersionCode = 0, ), SingleLang( - name = "Kuaikuai Manhua", baseUrl = "https://mobile.manhuaorg.com", lang = "zh", - className = "Kuaikuai", sourceName = "快快漫画", overrideVersionCode = 0 + name = "Kuaikuai Manhua", + baseUrl = "https://mobile.manhuaorg.com", + lang = "zh", + className = "Kuaikuai", + sourceName = "快快漫画", + overrideVersionCode = 0, ), SingleLang( - name = "bz Manhua", baseUrl = "https://www2.pupumanhua.com", lang = "zh", - className = "bzManhua", sourceName = "包子漫画搬运", overrideVersionCode = 0 + name = "bz Manhua", + baseUrl = "https://www2.pupumanhua.com", + lang = "zh", + className = "bzManhua", + sourceName = "包子漫画搬运", + overrideVersionCode = 0, ), // The following sources are from https://www.yy123.cyou/ and are configured to use MCCMSNsfw SingleLang( // 103=寄宿日记, same as: www.hanman.top (different URL format) - name = "Damao Manhua", baseUrl = "https://www.hanman.cyou", lang = "zh", isNsfw = true, - className = "DamaoManhua", sourceName = "大猫漫画", overrideVersionCode = 0 + name = "Damao Manhua", + baseUrl = "https://www.hanman.cyou", + lang = "zh", + isNsfw = true, + className = "DamaoManhua", + sourceName = "大猫漫画", + overrideVersionCode = 0, ), SingleLang( // 103=诡秘的姐妹 - name = "Heihei Manhua", baseUrl = "https://www.hhmh.cyou", lang = "zh", isNsfw = true, - className = "HHMH", sourceName = "嘿嘿漫画", overrideVersionCode = 0 + name = "Heihei Manhua", + baseUrl = "https://www.hhmh.cyou", + lang = "zh", + isNsfw = true, + className = "HHMH", + sourceName = "嘿嘿漫画", + overrideVersionCode = 0, ), SingleLang( // 103=望月仙女傳說, same as: www.hanman.men - name = "Tudou Manhua", baseUrl = "https://www.ptcomic.com", lang = "zh", isNsfw = true, - className = "PtComic", sourceName = "土豆漫画", overrideVersionCode = 0 + name = "Tudou Manhua", + baseUrl = "https://www.ptcomic.com", + lang = "zh", + isNsfw = true, + className = "PtComic", + sourceName = "土豆漫画", + overrideVersionCode = 0, ), SingleLang( // 103=校园梦精记, same as: www.hmanwang.com, www.quanman8.com, www.lmmh.cc, www.xinmanba.com - name = "Dida Manhua", baseUrl = "https://www.didamanhua.com", lang = "zh", isNsfw = true, - className = "DidaManhua", sourceName = "嘀嗒漫画", overrideVersionCode = 0 + name = "Dida Manhua", + baseUrl = "https://www.didamanhua.com", + lang = "zh", + isNsfw = true, + className = "DidaManhua", + sourceName = "嘀嗒漫画", + overrideVersionCode = 0, ), SingleLang( // 103=脱身之法, same as: www.quanmanba.com, www.999mh.net - name = "Dimanba", baseUrl = "https://www.dimanba.com", lang = "zh", isNsfw = true, - className = "Dimanba", sourceName = "滴漫吧", overrideVersionCode = 0 + name = "Dimanba", + baseUrl = "https://www.dimanba.com", + lang = "zh", + isNsfw = true, + className = "Dimanba", + sourceName = "滴漫吧", + overrideVersionCode = 0, ), ) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mdb/MDB.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mdb/MDB.kt index 856afa23b..a16abce4c 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mdb/MDB.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mdb/MDB.kt @@ -170,11 +170,15 @@ abstract class MDB( } override fun getFilterList() = - if (::categories.isInitialized) FilterList( - Filter.Header("如果使用文本搜索,将会忽略分类筛选"), - *categories.map { it.toFilter() }.toTypedArray() - ) else FilterList( - Filter.Header("点击“重置”即可刷新分类,如果失败,"), - Filter.Header("请尝试重新从图源列表点击进入图源"), - ) + if (::categories.isInitialized) { + FilterList( + Filter.Header("如果使用文本搜索,将会忽略分类筛选"), + *categories.map { it.toFilter() }.toTypedArray(), + ) + } else { + FilterList( + Filter.Header("点击“重置”即可刷新分类,如果失败,"), + Filter.Header("请尝试重新从图源列表点击进入图源"), + ) + } } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMS.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMS.kt index 0bd28e554..5c13088b9 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMS.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMS.kt @@ -42,6 +42,7 @@ abstract class MMRCMS( } else { sourceInfo } + /** * Parse a List of JSON sources into a list of `MyMangaReaderCMSSource`s * @@ -167,7 +168,7 @@ abstract class MMRCMS( // thumbnail_url = "$baseUrl/uploads/manga/$segment/cover/cover_250x350.jpg" } }, - false + false, ) } else { internalMangaParse(response) @@ -248,7 +249,7 @@ abstract class MMRCMS( } } }, - document.select(".pagination a[rel=next]").isNotEmpty() + document.select(".pagination a[rel=next]").isNotEmpty(), ) } @@ -268,17 +269,21 @@ abstract class MMRCMS( for (i in parsedBaseUrl.pathSegments) { if (i.trim().equals(newPathSegments.first(), true)) { newPathSegments.removeAt(0) - } else break + } else { + break + } } val builtUrl = parsedNewUrl.buildUpon().path("/") newPathSegments.forEach { builtUrl.appendPath(it) } var out = builtUrl.build().encodedPath!! - if (parsedNewUrl.encodedQuery != null) + if (parsedNewUrl.encodedQuery != null) { out += "?" + parsedNewUrl.encodedQuery - if (parsedNewUrl.encodedFragment != null) + } + if (parsedNewUrl.encodedFragment != null) { out += "#" + parsedNewUrl.encodedFragment + } return out } @@ -426,8 +431,8 @@ abstract class MMRCMS( "cat", arrayOf( "" to "Any", - *categoryMappings.toTypedArray() - ) + *categoryMappings.toTypedArray(), + ), ), UriSelectFilter( "Begins with", @@ -436,10 +441,10 @@ abstract class MMRCMS( "" to "Any", *"#ABCDEFGHIJKLMNOPQRSTUVWXYZ".toCharArray().map { Pair(it.toString(), it.toString()) - }.toTypedArray() - ) + }.toTypedArray(), + ), ), - SortFilter() + SortFilter(), ) /** @@ -454,9 +459,9 @@ abstract class MMRCMS( "tag", arrayOf( "" to "Any", - *tagMappings.toTypedArray() - ) - ) + *tagMappings.toTypedArray(), + ), + ), ) } else -> FilterList(getInitialFilterList()) @@ -474,12 +479,13 @@ abstract class MMRCMS( private val uriParam: String, private val vals: Array>, private val firstIsUnspecified: Boolean = true, - defaultValue: Int = 0 + defaultValue: Int = 0, ) : Filter.Select(displayName, vals.map { it.second }.toTypedArray(), defaultValue), UriFilter { override fun addToUri(uri: Uri.Builder) { - if (state != 0 || !firstIsUnspecified) + if (state != 0 || !firstIsUnspecified) { uri.appendQueryParameter(uriParam, vals[state].first) + } } } @@ -493,7 +499,7 @@ abstract class MMRCMS( Filter.Sort( "Sort", sortables.map { it.second }.toTypedArray(), - Selection(0, true) + Selection(0, true), ), UriFilter { override fun addToUri(uri: Uri.Builder) { @@ -505,7 +511,7 @@ abstract class MMRCMS( private val sortables = arrayOf( "name" to "Name", "views" to "Popularity", - "last_release" to "Last update" + "last_release" to "Last update", ) } } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSGenerator.kt index b3df43d25..6818d379c 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSGenerator.kt @@ -20,7 +20,7 @@ class MMRCMSGenerator : ThemeSourceGenerator { it.className, it.pkgName, it.sourceName, - it.overrideVersionCode + it.overrideVersionCode, ) } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSJsonGen.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSJsonGen.kt index f7b3dab35..1078b08c9 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSJsonGen.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mmrcms/MMRCMSJsonGen.kt @@ -185,7 +185,7 @@ class MMRCMSJsonGen { override fun getAcceptedIssuers(): Array { return arrayOf() } - } + }, ) // Install the all-trusting trust manager diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeAPI.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeAPI.kt index 6479e6c29..1bf8189e8 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeAPI.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeAPI.kt @@ -18,7 +18,7 @@ data class Results( private val offset: Int, private val limit: Int, private val results: List, - private val total: Int + private val total: Int, ) : Iterable by results { val hasNext: Boolean get() = total > results.size + offset * limit @@ -32,7 +32,7 @@ data class Manga( val artist: String, val status: String, val id: String, - private val version: Int + private val version: Int, ) { val cover: String get() = "/media/$id/cover.jpg?version=$version" @@ -47,7 +47,7 @@ data class Chapter( private val id: String, private val version: Int, private val length: Int, - private val uploadTime: String + private val uploadTime: String, ) { val title: String get() = buildString { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeCMS.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeCMS.kt index 8f0c4f7e5..90ca8ce62 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeCMS.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeCMS.kt @@ -18,7 +18,7 @@ import uy.kohesive.injekt.injectLazy open class MonochromeCMS( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : HttpSource() { override val supportsLatest = false @@ -45,10 +45,11 @@ open class MonochromeCMS( override fun fetchSearchManga( page: Int, query: String, - filters: FilterList + filters: FilterList, ): Observable { - if (!query.startsWith(UUID_QUERY)) + if (!query.startsWith(UUID_QUERY)) { return super.fetchSearchManga(page, query, filters) + } val req = GET("$apiUrl/manga/${query.substringAfter(UUID_QUERY)}") return client.newCall(req).asObservableSuccess().map { MangasPage(listOf(mangaFromAPI(it.decode())), false) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeGenerator.kt index c02426158..c0a850f35 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/monochrome/MonochromeGenerator.kt @@ -12,7 +12,7 @@ class MonochromeGenerator : ThemeSourceGenerator { override val sources = listOf( SingleLang("Monochrome Scans", "https://manga.d34d.one", "en"), - SingleLang("Monochrome Custom", "", "en") + SingleLang("Monochrome Custom", "", "en"), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/multichan/ChanGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/multichan/ChanGenerator.kt index 856430e2d..f45853ef0 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/multichan/ChanGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/multichan/ChanGenerator.kt @@ -14,7 +14,7 @@ class ChanGenerator : ThemeSourceGenerator { override val sources = listOf( SingleLang("MangaChan", "https://manga-chan.me", "ru", overrideVersionCode = 14), SingleLang("HenChan", "http://y.hchan.live", "ru", isNsfw = true, overrideVersionCode = 37), - SingleLang("YaoiChan", "https://yaoi-chan.me", "ru", isNsfw = true, overrideVersionCode = 4) + SingleLang("YaoiChan", "https://yaoi-chan.me", "ru", isNsfw = true, overrideVersionCode = 4), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/multichan/MultiChan.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/multichan/MultiChan.kt index c36f25b4c..d491857f8 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/multichan/MultiChan.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/multichan/MultiChan.kt @@ -19,7 +19,7 @@ import java.util.Locale abstract class MultiChan( override val name: String, override val baseUrl: String, - final override val lang: String + final override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = true diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMS.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMS.kt index 81f7d4bfd..5ed127e3f 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMS.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMS.kt @@ -26,7 +26,7 @@ import java.util.concurrent.TimeUnit abstract class MyMangaCMS( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = true @@ -42,7 +42,7 @@ abstract class MyMangaCMS( add("Referer", "$baseUrl/") add( "User-Agent", - "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:101.0) Gecko/20100101 Firefox/101.0" + "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:101.0) Gecko/20100101 Firefox/101.0", ) } @@ -77,7 +77,7 @@ abstract class MyMangaCMS( addPathSegment("tim-kiem") addQueryParameter("sort", "top") addQueryParameter("page", page.toString()) - }.build().toString() + }.build().toString(), ) override fun popularMangaSelector(): String = "div.thumb-item-flow.col-6.col-md-2" @@ -99,7 +99,7 @@ abstract class MyMangaCMS( addPathSegment("tim-kiem") addQueryParameter("sort", "update") addQueryParameter("page", page.toString()) - }.build().toString() + }.build().toString(), ) override fun latestUpdatesSelector(): String = popularMangaSelector() @@ -118,7 +118,7 @@ abstract class MyMangaCMS( fetchMangaDetails( SManga.create().apply { url = query.removePrefix(PREFIX_URL_SEARCH).trim().replace(baseUrl, "") - } + }, ) .map { MangasPage(listOf(it), false) } } @@ -161,7 +161,7 @@ abstract class MyMangaCMS( if (query.isNotEmpty()) { addQueryParameter("q", query) } - }.build().toString() + }.build().toString(), ) override fun searchMangaSelector(): String = popularMangaSelector() @@ -180,7 +180,7 @@ abstract class MyMangaCMS( setUrlWithoutDomain( document.select(".series-name-group a") .first() - .attr("abs:href") + .attr("abs:href"), ) title = document.select(".series-name").first().text().trim() @@ -245,7 +245,7 @@ abstract class MyMangaCMS( setUrlWithoutDomain(element.attr("abs:href")) name = element.select("div.chapter-name").first().text() date_upload = dateUpdatedParser( - element.select("div.chapter-time").first().text() + element.select("div.chapter-time").first().text(), ) val match = floatingNumberRegex.find(name) @@ -300,8 +300,8 @@ abstract class MyMangaCMS( "Tất cả", "Đang tiến hành", "Tạm ngưng", - "Hoàn thành" - ) + "Hoàn thành", + ), ) private class Sort : UriPartFilter( "Sắp xếp", @@ -313,7 +313,7 @@ abstract class MyMangaCMS( Pair("Xem nhiều", "top"), Pair("Được thích nhiều", "like"), ), - 4 + 4, ) open class Genre(name: String, val id: Int) : Filter.TriState(name) private class Author : Filter.Text("Tác giả") diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMSGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMSGenerator.kt index 54d0d91c2..902ab5284 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMSGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMSGenerator.kt @@ -16,7 +16,7 @@ class MyMangaCMSGenerator : ThemeSourceGenerator { "TruyenTranhLH", "https://truyentranhlh.net", "vi", - overrideVersionCode = 9 + overrideVersionCode = 9, ), SingleLang( "Phê Manga", @@ -26,7 +26,7 @@ class MyMangaCMSGenerator : ThemeSourceGenerator { "PheManga", "phemanga", ), - SingleLang("LKDTT", "https://lkdttzz.com", "vi", true, overrideVersionCode = 3) + SingleLang("LKDTT", "https://lkdttzz.com", "vi", true, overrideVersionCode = 3), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMSUrlActivity.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMSUrlActivity.kt index a1bf9e32d..80d56ff03 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMSUrlActivity.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mymangacms/MyMangaCMSUrlActivity.kt @@ -18,7 +18,7 @@ class MyMangaCMSUrlActivity : Activity() { action = "eu.kanade.tachiyomi.SEARCH" putExtra("query", "${MyMangaCMS.PREFIX_URL_SEARCH}${intent?.data?.path}") putExtra("filter", packageName) - } + }, ) } catch (e: ActivityNotFoundException) { Log.e("MyMangaCMSUrlActivity", e.toString()) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/nepnep/NepNep.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/nepnep/NepNep.kt index c9c184b78..00b6fb95b 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/nepnep/NepNep.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/nepnep/NepNep.kt @@ -33,7 +33,7 @@ import java.util.Locale abstract class NepNep( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : HttpSource() { override val supportsLatest = true @@ -51,6 +51,7 @@ abstract class NepNep( private fun JsonElement.getString(key: String): String? { return this.jsonObject[key]!!.jsonPrimitive.contentOrNull } + /** Returns value corresponding to given key as a JsonArray */ private fun JsonElement.getArray(key: String): JsonArray { return this.jsonObject[key]!!.jsonArray @@ -99,7 +100,7 @@ abstract class NepNep( title = directory[i].getString("s")!! url = "/manga/${directory[i].getString("i")}" thumbnail_url = getThumbnailUrl(directory[i].getString("i")!!) - } + }, ) } return MangasPage(mangas, endRange < directory.lastIndex) @@ -182,17 +183,21 @@ abstract class NepNep( directory.sortedByDescending { it.getString(sortBy) }.reversed() } } - is SelectField -> if (filter.state != 0) directory = when (filter.name) { - "Scan Status" -> directory.filter { it.getString("ss")!!.contains(filter.values[filter.state], ignoreCase = true) } - "Publish Status" -> directory.filter { it.getString("ps")!!.contains(filter.values[filter.state], ignoreCase = true) } - "Type" -> directory.filter { it.getString("t")!!.contains(filter.values[filter.state], ignoreCase = true) } - "Translation" -> directory.filter { it.getString("o")!!.contains("yes", ignoreCase = true) } - else -> directory + is SelectField -> if (filter.state != 0) { + directory = when (filter.name) { + "Scan Status" -> directory.filter { it.getString("ss")!!.contains(filter.values[filter.state], ignoreCase = true) } + "Publish Status" -> directory.filter { it.getString("ps")!!.contains(filter.values[filter.state], ignoreCase = true) } + "Type" -> directory.filter { it.getString("t")!!.contains(filter.values[filter.state], ignoreCase = true) } + "Translation" -> directory.filter { it.getString("o")!!.contains("yes", ignoreCase = true) } + else -> directory + } } is YearField -> if (filter.state.isNotEmpty()) directory = directory.filter { it.getString("y")!!.contains(filter.state) } - is AuthorField -> if (filter.state.isNotEmpty()) directory = directory.filter { e -> - e.getArray("a").any { - it.jsonPrimitive.content.contains(filter.state, ignoreCase = true) + is AuthorField -> if (filter.state.isNotEmpty()) { + directory = directory.filter { e -> + e.getArray("a").any { + it.jsonPrimitive.content.contains(filter.state, ignoreCase = true) + } } } is GenreList -> filter.state.forEach { genre -> @@ -204,14 +209,18 @@ abstract class NepNep( else -> continue } } - if (genres.isNotEmpty()) genres.map { genre -> - directory = directory.filter { e -> - e.getArray("g").any { it.jsonPrimitive.content.contains(genre, ignoreCase = true) } + if (genres.isNotEmpty()) { + genres.map { genre -> + directory = directory.filter { e -> + e.getArray("g").any { it.jsonPrimitive.content.contains(genre, ignoreCase = true) } + } } } - if (genresNo.isNotEmpty()) genresNo.map { genre -> - directory = directory.filterNot { e -> - e.getArray("g").any { it.jsonPrimitive.content.contains(genre, ignoreCase = true) } + if (genresNo.isNotEmpty()) { + genresNo.map { genre -> + directory = directory.filterNot { e -> + e.getArray("g").any { it.jsonPrimitive.content.contains(genre, ignoreCase = true) } + } } } @@ -331,8 +340,9 @@ abstract class NepNep( .substringAfter("vm.CurPathName = \"", "") .substringBefore("\"") .also { - if (it.isEmpty()) + if (it.isEmpty()) { throw Exception("$name is overloaded and blocking Tachiyomi right now. Wait for unblock.") + } } val titleURI = script.substringAfter("vm.IndexName = \"").substringBefore("\"") val seasonURI = curChapter.getString("Directory")!! @@ -366,7 +376,7 @@ abstract class NepNep( SelectField("Type", arrayOf("Any", "Doujinshi", "Manga", "Manhua", "Manhwa", "OEL", "One-shot")), SelectField("Translation", arrayOf("Any", "Official Only")), Sort(), - GenreList(getGenreList()) + GenreList(getGenreList()), ) // [...document.querySelectorAll("label.triStateCheckBox input")].map(el => `Filter("${el.getAttribute('name')}", "${el.nextSibling.textContent.trim()}")`).join(',\n') @@ -408,6 +418,6 @@ abstract class NepNep( Genre("Supernatural"), Genre("Tragedy"), Genre("Yaoi"), - Genre("Yuri") + Genre("Yuri"), ) } diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/otakusanctuary/OtakuSanctuary.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/otakusanctuary/OtakuSanctuary.kt index 4a6cb181f..692454d8b 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/otakusanctuary/OtakuSanctuary.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/otakusanctuary/OtakuSanctuary.kt @@ -49,7 +49,7 @@ open class OtakuSanctuary( FormBody.Builder().apply { add("Lang", helper.otakusanLang()) add("PageSize", "24") - }.build() + }.build(), ) private fun parseMangaCollection(elements: Elements): List { @@ -102,7 +102,7 @@ open class OtakuSanctuary( addPathSegments("Home/Search") addQueryParameter("search", query) }.build().toString(), - headers + headers, ) override fun searchMangaParse(response: Response): MangasPage { @@ -186,9 +186,9 @@ open class OtakuSanctuary( POST( "$baseUrl/Manga/UpdateView", headers, - FormBody.Builder().add("chapId", numericId).build() - ) - ).execute().body!!.string() + FormBody.Builder().add("chapId", numericId).build(), + ), + ).execute().body!!.string(), ).jsonObject if (data["view"] != null) { @@ -224,9 +224,9 @@ open class OtakuSanctuary( POST( "$baseUrl/Manga/CheckingAlternate", headers, - FormBody.Builder().add("chapId", numericId).build() - ) - ).execute().body!!.string() + FormBody.Builder().add("chapId", numericId).build(), + ), + ).execute().body!!.string(), ).jsonObject val content = alternate["Content"]?.jsonPrimitive?.content ?: throw Exception("No pages found") diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/otakusanctuary/OtakuSanctuaryGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/otakusanctuary/OtakuSanctuaryGenerator.kt index 5a7081a1a..6c03a19bb 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/otakusanctuary/OtakuSanctuaryGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/otakusanctuary/OtakuSanctuaryGenerator.kt @@ -16,13 +16,13 @@ class OtakuSanctuaryGenerator : ThemeSourceGenerator { "Otaku Sanctuary", "https://otakusan.net", listOf("all", "vi", "en", "it", "fr", "es"), - isNsfw = true + isNsfw = true, ), MultiLang( "MyRockManga", "https://myrockmanga.com", listOf("all", "vi", "en", "it", "fr", "es"), - isNsfw = true + isNsfw = true, ), ) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/Paprika.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/Paprika.kt index 0933fc414..994762fde 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/Paprika.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/Paprika.kt @@ -22,7 +22,7 @@ import java.util.Locale abstract class Paprika( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = true @@ -187,7 +187,7 @@ abstract class Paprika( Filter.Header("NOTE: Ignored if using text search!"), Filter.Separator(), OrderFilter(getOrderList()), - GenreFilter(getGenreList()) + GenreFilter(getGenreList()), ) class OrderFilter(vals: Array>) : UriPartFilter("Category", vals) @@ -195,7 +195,7 @@ abstract class Paprika( private fun getOrderList() = arrayOf( Pair("Views", "2"), Pair("Latest", "3"), - Pair("A-Z", "1") + Pair("A-Z", "1"), ) class GenreFilter(vals: Array>) : UriPartFilter("Category", vals) @@ -298,7 +298,7 @@ abstract class Paprika( Pair("Wuxia", "wuxia"), Pair("Yaoi", "yaoi"), Pair("Yuri", "yuri"), - Pair("Zombies", "zombies") + Pair("Zombies", "zombies"), ) open class UriPartFilter(displayName: String, private val vals: Array>) : diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/PaprikaAlt.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/PaprikaAlt.kt index f3ab8fedc..29be76e01 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/PaprikaAlt.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/PaprikaAlt.kt @@ -14,7 +14,7 @@ import org.jsoup.nodes.Element abstract class PaprikaAlt( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : Paprika(name, baseUrl, lang) { override fun popularMangaSelector() = "div.anipost" diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/PaprikaAltGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/PaprikaAltGenerator.kt index a42425b63..da30259f5 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/PaprikaAltGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/paprika/PaprikaAltGenerator.kt @@ -12,7 +12,7 @@ class PaprikaAltGenerator : ThemeSourceGenerator { override val baseVersionCode: Int = 1 override val sources = listOf( - SingleLang("MangaReader.cc", "http://mangareader.cc/", "en", className = "MangaReaderCC", overrideVersionCode = 1) // more sites in the future might use MangaReader.cc 's overrides as they did in the past + SingleLang("MangaReader.cc", "http://mangareader.cc/", "en", className = "MangaReaderCC", overrideVersionCode = 1), // more sites in the future might use MangaReader.cc 's overrides as they did in the past ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReader.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReader.kt index 57de3377d..128786a3e 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReader.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReader.kt @@ -24,7 +24,7 @@ abstract class PizzaReader( override val baseUrl: String, override val lang: String, private val apiPath: String = "/api", - private val dateParser: SimpleDateFormat = SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSSSS", Locale.ITALY) + private val dateParser: SimpleDateFormat = SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSSSS", Locale.ITALY), ) : HttpSource() { override val supportsLatest = true diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReaderDto.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReaderDto.kt index a3113de39..7464a559f 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReaderDto.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReaderDto.kt @@ -5,18 +5,18 @@ import kotlinx.serialization.Serializable @Serializable data class PizzaResultsDto( - val comics: List = emptyList() + val comics: List = emptyList(), ) @Serializable data class PizzaResultDto( - val comic: PizzaComicDto? = null + val comic: PizzaComicDto? = null, ) @Serializable data class PizzaReaderDto( val chapter: PizzaChapterDto? = null, - val comic: PizzaComicDto? = null + val comic: PizzaComicDto? = null, ) @Serializable @@ -30,12 +30,12 @@ data class PizzaComicDto( val status: String = "", val title: String = "", val thumbnail: String = "", - val url: String = "" + val url: String = "", ) @Serializable data class PizzaGenreDto( - val name: String = "" + val name: String = "", ) @Serializable @@ -46,10 +46,10 @@ data class PizzaChapterDto( @SerialName("published_on") val publishedOn: String = "", val subchapter: Int? = null, val teams: List = emptyList(), - val url: String = "" + val url: String = "", ) @Serializable data class PizzaTeamDto( - val name: String = "" + val name: String = "", ) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReaderGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReaderGenerator.kt index a6a698552..80c53c831 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReaderGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/pizzareader/PizzaReaderGenerator.kt @@ -16,7 +16,7 @@ class PizzaReaderGenerator : ThemeSourceGenerator { SingleLang("Phoenix Scans", "https://www.phoenixscans.com", "it", className = "PhoenixScans", overrideVersionCode = 4), SingleLang("GTO The Great Site", "https://reader.gtothegreatsite.net", "it", className = "GTO", overrideVersionCode = 3), SingleLang("LupiTeam", "https://lupiteam.net", "it", overrideVersionCode = 3), - SingleLang("TuttoAnimeManga", "https://tuttoanimemanga.net", "it", overrideVersionCode = 4) + SingleLang("TuttoAnimeManga", "https://tuttoanimemanga.net", "it", overrideVersionCode = 4), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/readerfront/ReaderFront.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/readerfront/ReaderFront.kt index b5093c6c9..db190f666 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/readerfront/ReaderFront.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/readerfront/ReaderFront.kt @@ -20,7 +20,7 @@ import uy.kohesive.injekt.injectLazy abstract class ReaderFront( final override val name: String, final override val baseUrl: String, - final override val lang: String + final override val lang: String, ) : HttpSource() { override val supportsLatest = true diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/readerfront/ReaderFrontAPI.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/readerfront/ReaderFrontAPI.kt index cc06db33d..be1dc34ed 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/readerfront/ReaderFrontAPI.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/readerfront/ReaderFrontAPI.kt @@ -18,7 +18,7 @@ data class Work( val description: String? = null, val demographic_name: String? = null, val genres: List? = null, - private val people_works: List? = null + private val people_works: List? = null, ) { @Transient val authors = people_works?.filter { it.role == 1 } @@ -36,7 +36,7 @@ data class Release( private val subchapter: Int, private val volume: Int, private val name: String, - private val releaseDate: String + private val releaseDate: String, ) { @Transient val number = "$chapter.$subchapter".toFloat() @@ -66,7 +66,7 @@ data class Release( data class Chapter( private val uniqid: String, private val work: UniqidWrapper, - private val pages: List + private val pages: List, ) : Iterable by pages { /** Get the path of a page in the list. */ fun path(page: Page) = "/works/$work/$this/$page" diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/sinmh/SinMH.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/sinmh/SinMH.kt index b94c657fa..fac5e745f 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/sinmh/SinMH.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/sinmh/SinMH.kt @@ -212,7 +212,9 @@ abstract class SinMH( protected open fun parsePageImages(chapterImages: String): List = if (chapterImages.length > 4) { chapterImages.run { substring(2, length - 2) }.replace("""\/""", "/").split("\",\"") - } else emptyList() // [] + } else { + emptyList() // [] + } override fun imageUrlParse(document: Document): String = throw UnsupportedOperationException("Not Used.") diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/sinmh/SinMHGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/sinmh/SinMHGenerator.kt index 08f6d8c7c..e82a1722d 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/sinmh/SinMHGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/sinmh/SinMHGenerator.kt @@ -9,24 +9,45 @@ class SinMHGenerator : ThemeSourceGenerator { override val baseVersionCode = 8 override val sources = listOf( SingleLang( - name = "Gufeng Manhua", baseUrl = "https://www.123gf.com", lang = "zh", - className = "Gufengmh", sourceName = "古风漫画网", overrideVersionCode = 6 + name = "Gufeng Manhua", + baseUrl = "https://www.123gf.com", + lang = "zh", + className = "Gufengmh", + sourceName = "古风漫画网", + overrideVersionCode = 6, ), SingleLang( - name = "Imitui Manhua", baseUrl = "https://www.imitui.com", lang = "zh", - className = "Imitui", sourceName = "爱米推漫画", overrideVersionCode = 3 + name = "Imitui Manhua", + baseUrl = "https://www.imitui.com", + lang = "zh", + className = "Imitui", + sourceName = "爱米推漫画", + overrideVersionCode = 3, ), SingleLang( // This site blocks IP outside China - name = "YKMH", baseUrl = "http://www.ykmh.com", lang = "zh", className = "YKMH", - pkgName = "manhuadui", sourceName = "优酷漫画", overrideVersionCode = 17 + name = "YKMH", + baseUrl = "http://www.ykmh.com", + lang = "zh", + className = "YKMH", + pkgName = "manhuadui", + sourceName = "优酷漫画", + overrideVersionCode = 17, ), SingleLang( - name = "Qinqin Manhua", baseUrl = "https://www.acgqd.com", lang = "zh", - className = "Qinqin", sourceName = "亲亲漫画", overrideVersionCode = 1 + name = "Qinqin Manhua", + baseUrl = "https://www.acgqd.com", + lang = "zh", + className = "Qinqin", + sourceName = "亲亲漫画", + overrideVersionCode = 1, ), SingleLang( - name = "57Manhua", baseUrl = "http://www.wuqimh.net", lang = "zh", - className = "WuqiManga", sourceName = "57漫画", overrideVersionCode = 5 + name = "57Manhua", + baseUrl = "http://www.wuqimh.net", + lang = "zh", + className = "WuqiManga", + sourceName = "57漫画", + overrideVersionCode = 5, ), ) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/Webtoons.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/Webtoons.kt index 9618f55e5..4baf9de8c 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/Webtoons.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/Webtoons.kt @@ -39,7 +39,7 @@ open class Webtoons( override val lang: String, open val langCode: String = lang, open val localeForCookie: String = lang, - private val dateFormat: SimpleDateFormat = SimpleDateFormat("MMM d, yyyy", Locale.ENGLISH) + private val dateFormat: SimpleDateFormat = SimpleDateFormat("MMM d, yyyy", Locale.ENGLISH), ) : ParsedHttpSource() { override val supportsLatest = true @@ -59,10 +59,10 @@ open class Webtoons( .value(localeForCookie) .name("needGDPR") .value("false") - .build() + .build(), ) } - } + }, ) .addInterceptor(::sslRetryInterceptor) .build() @@ -149,8 +149,9 @@ open class Webtoons( override fun latestUpdatesNextPageSelector(): String? = null override fun fetchSearchManga(page: Int, query: String, filters: FilterList): Observable { - if (!query.startsWith(URL_SEARCH_PREFIX)) + if (!query.startsWith(URL_SEARCH_PREFIX)) { return super.fetchSearchManga(page, query, filters) + } val emptyResult = Observable.just(MangasPage(emptyList(), false)) @@ -164,9 +165,9 @@ open class Webtoons( val title_no = url.queryParameter("title_no") val couldBeWebtoonOrEpisode = title_no != null && (url.pathSegments.size >= 3 && url.pathSegments.last().isNotEmpty()) val isThisLang = "$url".startsWith("$baseUrl/$langCode") - if (! (couldBeWebtoonOrEpisode && isThisLang)) + if (!(couldBeWebtoonOrEpisode && isThisLang)) { emptyResult - else { + } else { val potentialUrl = "${webtoonPath(url)}?title_no=$title_no" fetchMangaDetails(SManga.create().apply { this.url = potentialUrl }).map { it.url = potentialUrl @@ -227,7 +228,7 @@ open class Webtoons( return FilterList( Header("Query can not be blank"), Separator(), - SearchType(getOfficialList()) + SearchType(getOfficialList()), ) } @@ -238,7 +239,7 @@ open class Webtoons( private fun getOfficialList() = arrayOf( Pair("Any", ""), Pair("Official only", "WEBTOON"), - Pair("Challenge only", "CHALLENGE") + Pair("Challenge only", "CHALLENGE"), ) open class UriPartFilter(displayName: String, private val vals: Array>) : diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/WebtoonsGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/WebtoonsGenerator.kt index ca8bdf1cd..e100a9560 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/WebtoonsGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/WebtoonsGenerator.kt @@ -14,7 +14,7 @@ class WebtoonsGenerator : ThemeSourceGenerator { override val sources = listOf( MultiLang("Webtoons.com", "https://www.webtoons.com", listOf("en", "fr", "es", "id", "th", "zh-Hant", "de"), className = "WebtoonsFactory", pkgName = "webtoons", overrideVersionCode = 37), - SingleLang("Dongman Manhua", "https://www.dongmanmanhua.cn", "zh") + SingleLang("Dongman Manhua", "https://www.dongmanmanhua.cn", "zh"), ) companion object { diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/WebtoonsTranslate.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/WebtoonsTranslate.kt index 7c5b967d1..b871758ac 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/WebtoonsTranslate.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/webtoons/WebtoonsTranslate.kt @@ -28,7 +28,7 @@ open class WebtoonsTranslate( override val name: String, override val baseUrl: String, override val lang: String, - private val translateLangCode: String + private val translateLangCode: String, ) : Webtoons(name, baseUrl, lang) { // popularMangaRequest already returns manga sorted by latest update diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/weebreader/Weebreader.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/weebreader/Weebreader.kt index 63a389fcd..68f1e5f2f 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/weebreader/Weebreader.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/weebreader/Weebreader.kt @@ -89,8 +89,9 @@ abstract class Weebreader( override fun mangaDetailsParse(response: Response): SManga { val titleJson = json.parseToJsonElement(response.body!!.string()).jsonObject - if (titleJson["type"]!!.jsonPrimitive.content != "Comic") + if (titleJson["type"]!!.jsonPrimitive.content != "Comic") { throw UnsupportedOperationException("Tachiyomi only supports Comics.") + } return SManga.create().apply { title = titleJson["name"]!!.jsonPrimitive.content @@ -109,8 +110,9 @@ abstract class Weebreader( override fun chapterListParse(response: Response): List { val titleJson = json.parseToJsonElement(response.body!!.string()).jsonObject - if (titleJson["type"]!!.jsonPrimitive.content != "Comic") + if (titleJson["type"]!!.jsonPrimitive.content != "Comic") { throw UnsupportedOperationException("Tachiyomi only supports Comics.") + } return titleJson["chapters"]!!.jsonArray.map { val chapter = it.jsonObject diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/wpcomics/WPComics.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/wpcomics/WPComics.kt index 5fce833f9..4d2cca32d 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/wpcomics/WPComics.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/wpcomics/WPComics.kt @@ -22,7 +22,7 @@ abstract class WPComics( override val baseUrl: String, override val lang: String, private val dateFormat: SimpleDateFormat = SimpleDateFormat("HH:mm - dd/MM/yyyy Z", Locale.US), - private val gmtOffset: String? = "+0500" + private val gmtOffset: String? = "+0500", ) : ParsedHttpSource() { override val supportsLatest = true @@ -231,7 +231,7 @@ abstract class WPComics( Pair(null, "Tất cả"), Pair("1", "Đang tiến hành"), Pair("2", "Đã hoàn thành"), - Pair("3", "Tạm ngừng") + Pair("3", "Tạm ngừng"), ) protected open fun getGenreList(): Array> = arrayOf( null to "Tất cả", @@ -285,7 +285,7 @@ abstract class WPComics( "truyen-scan" to "Truyện scan", "truyen-mau" to "Truyện Màu", "webtoon" to "Webtoon", - "xuyen-khong" to "Xuyên Không" + "xuyen-khong" to "Xuyên Không", ) protected open class UriPartFilter(displayName: String, val vals: Array>) : diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zbulu/Zbulu.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zbulu/Zbulu.kt index aa2eb6c35..4727849e0 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zbulu/Zbulu.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zbulu/Zbulu.kt @@ -22,7 +22,7 @@ import java.util.concurrent.TimeUnit abstract class Zbulu( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = true @@ -204,7 +204,7 @@ abstract class Zbulu( Filter.Header("Author name must be exact."), Filter.Separator(), AuthorFilter(), - GenreFilter() + GenreFilter(), ) // [...document.querySelectorAll('.sub-menu li a')].map(a => `Pair("${a.textContent}", "${a.getAttribute('href')}")`).join(',\n') @@ -259,8 +259,8 @@ abstract class Zbulu( Pair("Supernatural", "supernatural"), Pair("Tragedy", "tragedy"), Pair("Trap", "trap"), - Pair("Webtoons", "webtoons") - ) + Pair("Webtoons", "webtoons"), + ), ) private open class UriPartFilter(displayName: String, val vals: Array>) : diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zeistmanga/ZeistManga.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zeistmanga/ZeistManga.kt index 8ecd4f21d..480ea958a 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zeistmanga/ZeistManga.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zeistmanga/ZeistManga.kt @@ -21,7 +21,7 @@ import uy.kohesive.injekt.injectLazy abstract class ZeistManga( override val name: String, override val baseUrl: String, - override val lang: String + override val lang: String, ) : ParsedHttpSource() { override val supportsLatest = false diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zeistmanga/ZeistMangaDto.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zeistmanga/ZeistMangaDto.kt index 25c66b9bb..ade10eb2c 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zeistmanga/ZeistMangaDto.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zeistmanga/ZeistMangaDto.kt @@ -24,7 +24,7 @@ data class ZeistMangaDto( @Serializable data class ZeistMangaFeedDto( - val entry: List? = emptyList() + val entry: List? = emptyList(), ) @Serializable @@ -32,7 +32,7 @@ data class ZeistMangaEntryDto( val title: ZeistMangaEntryTitleDto? = null, val published: ZeistMangaEntryPublishedDto? = null, @SerialName("link") val url: List? = emptyList(), - val content: ZeistMangaEntryContentDto? = null + val content: ZeistMangaEntryContentDto? = null, ) { fun toSManga(baseurl: String): SManga = SManga.create().apply { title = this@ZeistMangaEntryDto.title!!.t @@ -59,21 +59,21 @@ data class ZeistMangaEntryDto( @Serializable data class ZeistMangaEntryTitleDto( - @SerialName("\$t") val t: String + @SerialName("\$t") val t: String, ) @Serializable data class ZeistMangaEntryPublishedDto( - @SerialName("\$t") val t: String + @SerialName("\$t") val t: String, ) @Serializable data class ZeistMangaEntryContentDto( - @SerialName("\$t") val t: String + @SerialName("\$t") val t: String, ) @Serializable data class ZeistMangaEntryLink( val rel: String, - val href: String + val href: String, ) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zmanga/ZManga.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zmanga/ZManga.kt index 8d4db2e0e..e0db46eef 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zmanga/ZManga.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/zmanga/ZManga.kt @@ -198,7 +198,7 @@ abstract class ZManga( Filter.Header("NOTE: cant be used with other filter!"), Filter.Header("$name Project List page"), ProjectFilter(), - ) + ), ) } return FilterList(filters) @@ -208,8 +208,8 @@ abstract class ZManga( "Filter Project", arrayOf( Pair("Show all manga", ""), - Pair("Show only project manga", "project-filter-on") - ) + Pair("Show only project manga", "project-filter-on"), + ), ) private class AuthorFilter : Filter.Text("Author") @@ -226,8 +226,8 @@ abstract class ZManga( Pair("Manhua", "Manhua"), Pair("Manhwa", "Manhwa"), Pair("One-Shot", "One-Shot"), - Pair("Doujin", "Doujin") - ) + Pair("Doujin", "Doujin"), + ), ) private class OrderByFilter : UriPartFilter( "Order By", @@ -238,8 +238,8 @@ abstract class ZManga( Pair("Latest Update", "update"), Pair("Latest Added", "latest"), Pair("Popular", "popular"), - Pair("Rating", "rating") - ) + Pair("Rating", "rating"), + ), ) private fun getGenreList() = listOf( @@ -297,7 +297,7 @@ abstract class ZManga( Tag("tragedy", "Tragedy"), Tag("vampire", "Vampire"), Tag("webtoons", "Webtoons"), - Tag("yuri", "Yuri") + Tag("yuri", "Yuri"), ) open class UriPartFilter(displayName: String, val vals: Array>) : diff --git a/multisrc/src/main/java/generator/IntelijConfigurationGeneratorMain.kt b/multisrc/src/main/java/generator/IntelijConfigurationGeneratorMain.kt index ee6476053..d3c7e6b46 100644 --- a/multisrc/src/main/java/generator/IntelijConfigurationGeneratorMain.kt +++ b/multisrc/src/main/java/generator/IntelijConfigurationGeneratorMain.kt @@ -13,8 +13,9 @@ fun main(args: Array) { // cleanup from past runs File("$userDir/.run").apply { - if (exists()) + if (exists()) { deleteRecursively() + } mkdirs() } diff --git a/multisrc/src/main/java/generator/ThemeSourceGenerator.kt b/multisrc/src/main/java/generator/ThemeSourceGenerator.kt index 277daeeda..6901f3186 100644 --- a/multisrc/src/main/java/generator/ThemeSourceGenerator.kt +++ b/multisrc/src/main/java/generator/ThemeSourceGenerator.kt @@ -58,7 +58,7 @@ interface ThemeSourceGenerator { val additionalGradleOverrideText = File(additionalGradleOverridePath).readTextOrEmptyString() val placeholders = mapOf( "SOURCEHOST" to source.baseUrl.toHttpUrlOrNull()?.host, - "SOURCESCHEME" to source.baseUrl.toHttpUrlOrNull()?.scheme + "SOURCESCHEME" to source.baseUrl.toHttpUrlOrNull()?.scheme, ) val placeholdersStr = placeholders @@ -92,7 +92,7 @@ interface ThemeSourceGenerator { | ] | } |} - """.trimMargin() + """.trimMargin(), ) } @@ -109,7 +109,7 @@ interface ThemeSourceGenerator { | | | - """.trimMargin() + """.trimMargin(), ) } } @@ -158,7 +158,7 @@ interface ThemeSourceGenerator { Files.copy( File("$path/$it").toPath(), File("$projectRootPath/$it").toPath(), - StandardCopyOption.REPLACE_EXISTING + StandardCopyOption.REPLACE_EXISTING, ) } } @@ -178,12 +178,13 @@ interface ThemeSourceGenerator { private fun copyResFiles(resOverridePath: String, defaultResPath: String, source: ThemeSourceData, projectRootPath: String): Any { // check if res override exists if not copy default res val resOverride = File(resOverridePath) - return if (resOverride.exists()) + return if (resOverride.exists()) { resOverride.copyRecursively(File("$projectRootPath/res")) - else + } else { File(defaultResPath).let { defaultResFile -> if (defaultResFile.exists()) defaultResFile.copyRecursively(File("$projectRootPath/res")) } + } } private fun writeSourceClasses(projectSrcPath: String, srcOverridePath: String, source: ThemeSourceData, themePkg: String, themeClass: String) { @@ -228,7 +229,7 @@ interface ThemeSourceGenerator { |${if (source is ThemeSourceData.MultiLang) "import eu.kanade.tachiyomi.source.SourceFactory" else ""} | |${factoryClassText()} - """.trimMargin() + """.trimMargin(), ) } diff --git a/src/all/batoto/src/eu/kanade/tachiyomi/extension/all/batoto/BatoTo.kt b/src/all/batoto/src/eu/kanade/tachiyomi/extension/all/batoto/BatoTo.kt index 10cffb1fe..6e36c0ff7 100644 --- a/src/all/batoto/src/eu/kanade/tachiyomi/extension/all/batoto/BatoTo.kt +++ b/src/all/batoto/src/eu/kanade/tachiyomi/extension/all/batoto/BatoTo.kt @@ -46,7 +46,7 @@ import java.util.concurrent.TimeUnit open class BatoTo( final override val lang: String, - private val siteLang: String + private val siteLang: String, ) : ConfigurableSource, ParsedHttpSource() { private val preferences: SharedPreferences by lazy { @@ -200,7 +200,8 @@ open class BatoTo( is GenreGroupFilter -> { with(filter) { url.addQueryParameter( - "genres", included.joinToString(",") + "|" + excluded.joinToString(",") + "genres", + included.joinToString(",") + "|" + excluded.joinToString(","), ) } } @@ -344,8 +345,8 @@ open class BatoTo( when { manga.url.startsWith("http") -> manga.url else -> "$baseUrl${manga.url}" - } - ) + }, + ), ).execute().asJsoup() if (getAltChapterListPref() || checkChapterLists(url)) { val id = manga.url.substringBeforeLast("/").substringAfterLast("/").trim() @@ -819,7 +820,7 @@ open class BatoTo( TriStateFilterOption("lolicon", "lolicon"), TriStateFilterOption("award_winning", "Award Winning"), TriStateFilterOption("youkai", "Youkai"), - TriStateFilterOption("uncategorized", "Uncategorized") + TriStateFilterOption("uncategorized", "Uncategorized"), ) private fun getLangFilter() = listOf( @@ -949,7 +950,7 @@ open class BatoTo( "dto.to", "hto.to", "mto.to", - "wto.to" + "wto.to", ) private val MIRROR_PREF_ENTRY_VALUES = arrayOf( "https://bato.to", @@ -965,7 +966,7 @@ open class BatoTo( "https://dto.to", "https://hto.to", "https://mto.to", - "https://wto.to" + "https://wto.to", ) private val MIRROR_PREF_DEFAULT_VALUE = MIRROR_PREF_ENTRY_VALUES[0] diff --git a/src/all/batoto/src/eu/kanade/tachiyomi/extension/all/batoto/BatoToFactory.kt b/src/all/batoto/src/eu/kanade/tachiyomi/extension/all/batoto/BatoToFactory.kt index c17052cc2..2a4ee05ee 100644 --- a/src/all/batoto/src/eu/kanade/tachiyomi/extension/all/batoto/BatoToFactory.kt +++ b/src/all/batoto/src/eu/kanade/tachiyomi/extension/all/batoto/BatoToFactory.kt @@ -65,7 +65,7 @@ private val languages = listOf( LanguageOption("ka"), LanguageOption("gn"), LanguageOption("gu"), - LanguageOption("ht",), + LanguageOption("ht"), LanguageOption("ha"), LanguageOption("is"), LanguageOption("ig"), @@ -95,7 +95,7 @@ private val languages = listOf( LanguageOption("rm"), LanguageOption("sm"), LanguageOption("sr"), - LanguageOption("sh",), + LanguageOption("sh"), LanguageOption("st"), LanguageOption("sn"), LanguageOption("sd"), diff --git a/src/all/buondua/src/eu/kanade/tachiyomi/extension/all/buondua/BuonDua.kt b/src/all/buondua/src/eu/kanade/tachiyomi/extension/all/buondua/BuonDua.kt index 46d9700ca..44282a32e 100644 --- a/src/all/buondua/src/eu/kanade/tachiyomi/extension/all/buondua/BuonDua.kt +++ b/src/all/buondua/src/eu/kanade/tachiyomi/extension/all/buondua/BuonDua.kt @@ -89,7 +89,7 @@ class BuonDua() : ParsedHttpSource() { val numpages = document.selectFirst(".pagination-list").select(".pagination-link") val pages = mutableListOf() - numpages.forEachIndexed() { index, page -> + numpages.forEachIndexed { index, page -> val doc = when (index) { 0 -> document else -> client.newCall(GET(page.attr("abs:href"))).execute().asJsoup() diff --git a/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFun.kt b/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFun.kt index 4262d3229..d1f26cd3a 100644 --- a/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFun.kt +++ b/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFun.kt @@ -57,7 +57,7 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S addQueryParameter("page", "$page") addQueryParameter("tachiyomi", "true") }.toString(), - headers + headers, ) } @@ -71,7 +71,7 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S thumbnail_url = data.cover_url } }, - hasNextPage = true + hasNextPage = true, ) } @@ -86,7 +86,7 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S addQueryParameter("page", "$page") addQueryParameter("tachiyomi", "true") }.toString(), - headers + headers, ) } @@ -100,7 +100,7 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S thumbnail_url = data.cover_url } }, - hasNextPage = true + hasNextPage = true, ) } @@ -119,27 +119,31 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S is GenreFilter -> { it.state.filter { (it as TriState).isIncluded() }.forEach { addQueryParameter( - "genres", (it as TriState).value + "genres", + (it as TriState).value, ) } it.state.filter { (it as TriState).isExcluded() }.forEach { addQueryParameter( - "excludes", (it as TriState).value + "excludes", + (it as TriState).value, ) } } is DemographicFilter -> { it.state.filter { (it as CheckBox).state }.forEach { addQueryParameter( - "demographic", (it as CheckBox).value + "demographic", + (it as CheckBox).value, ) } } is TypeFilter -> { it.state.filter { (it as CheckBox).state }.forEach { addQueryParameter( - "country", (it as CheckBox).value + "country", + (it as CheckBox).value, ) } } @@ -195,7 +199,7 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S thumbnail_url = data.cover_url } }, - hasNextPage = result.size >= 30 + hasNextPage = result.size >= 30, ) } @@ -206,8 +210,8 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S "$API_BASE${manga.url}".toHttpUrl().newBuilder().apply { addQueryParameter("tachiyomi", "true") }.toString(), - headers - ) + headers, + ), ).asObservableSuccess() .map { response -> mangaDetailsParse(response).apply { initialized = true } } } @@ -236,7 +240,7 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S "$API_BASE${manga.url}".toHttpUrl().newBuilder().apply { addQueryParameter("tachiyomi", "true") }.toString(), - headers + headers, ) } @@ -251,11 +255,12 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S addPathSegments("chapters") if (comickFunLang != "all") addQueryParameter("lang", comickFunLang) addQueryParameter( - "limit", mangaData.comic.chapter_count.toString() + "limit", + mangaData.comic.chapter_count.toString(), ) }.toString(), - headers - ) + headers, + ), ).execute() val result = json.decodeFromString(chapterData.body!!.string()) return result.chapters.map { chapter -> @@ -287,7 +292,7 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S addPathSegment(chapterHid) addQueryParameter("tachiyomi", "true") }.toString(), - headers + headers, ) } @@ -308,7 +313,7 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S } override fun getFilterList() = FilterList( - getFilters() + getFilters(), ) /** Map the slug to comic ID as slug might be changes by comic ID will not. **/ @@ -321,8 +326,8 @@ abstract class ComickFun(override val lang: String, private val comickFunLang: S addPathSegment("mapping") addQueryParameter("slugs", oldSlug) }.toString(), - headers - ) + headers, + ), ).execute() /** If the API does not contain the ID for the slug, return the slug back **/ diff --git a/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunDto.kt b/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunDto.kt index 2a4b33ee6..b323a00a0 100644 --- a/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunDto.kt +++ b/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunDto.kt @@ -7,7 +7,7 @@ data class Manga( val hid: String, val slug: String, val title: String, - val cover_url: String + val cover_url: String, ) @Serializable @@ -15,7 +15,7 @@ data class MangaDetails( val comic: Comic, val artists: Array, val authors: Array, - val genres: Array + val genres: Array, ) @Serializable @@ -26,7 +26,7 @@ data class Comic( val desc: String = "N/A", val status: Int, val chapter_count: Int?, - val cover_url: String + val cover_url: String, ) @Serializable @@ -49,7 +49,7 @@ data class Genre( @Serializable data class ChapterList( - val chapters: Array + val chapters: Array, ) @Serializable @@ -59,20 +59,20 @@ data class Chapter( val created_at: String = "", val chap: String = "", val vol: String = "", - val group_name: Array = arrayOf("") + val group_name: Array = arrayOf(""), ) @Serializable data class PageList( - val chapter: ChapterPageData + val chapter: ChapterPageData, ) @Serializable data class ChapterPageData( - val images: Array + val images: Array, ) @Serializable data class Page( - val url: String? = null + val url: String? = null, ) diff --git a/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunFactory.kt b/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunFactory.kt index 3368d84b4..ef9cf7c3f 100644 --- a/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunFactory.kt +++ b/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunFactory.kt @@ -52,7 +52,7 @@ class ComickFunFactory : SourceFactory { "lt" to 1792260331167396074, "el" to 6190162673651111756, "sr" to 571668187470919545, - "da" to 7137437402245830147 + "da" to 7137437402245830147, ).toMap() override fun createSources(): List = idMap.keys.map { object : ComickFun(legacyLanguageMappings.getValue(it), it) { diff --git a/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunFilters.kt b/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunFilters.kt index 18bcd0ff4..833a2c2a0 100644 --- a/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunFilters.kt +++ b/src/all/comickfun/src/eu/kanade/tachiyomi/extension/all/comickfun/ComickFunFilters.kt @@ -147,7 +147,7 @@ private val getGenresList: List = listOf( TriState("Wuxia", "wuxia"), TriState("Yaoi", "yaoi"), TriState("Yuri", "yuri"), - TriState("Zombies", "zombies") + TriState("Zombies", "zombies"), ) private val getDemographicList: List = listOf( @@ -175,5 +175,5 @@ private val getSortsList: Array> = arrayOf( Pair("Most follows", "user_follow_count"), Pair("Most views", "view"), Pair("High rating", "rating"), - Pair("Last updated", "uploaded") + Pair("Last updated", "uploaded"), ) diff --git a/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/Comico.kt b/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/Comico.kt index e0bbfa456..653b77147 100644 --- a/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/Comico.kt +++ b/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/Comico.kt @@ -32,7 +32,7 @@ import java.util.Locale open class Comico( final override val baseUrl: String, final override val name: String, - private val langCode: String + private val langCode: String, ) : HttpSource() { final override val supportsLatest = true @@ -62,16 +62,18 @@ open class Comico( }.build() override val client = network.client.newBuilder() - .cookieJar(object : CookieJar { - override fun saveFromResponse(url: HttpUrl, cookies: List) = - cookies.filter { it.matches(url) }.forEach { - cookieManager.setCookie(url.toString(), it.toString()) - } + .cookieJar( + object : CookieJar { + override fun saveFromResponse(url: HttpUrl, cookies: List) = + cookies.filter { it.matches(url) }.forEach { + cookieManager.setCookie(url.toString(), it.toString()) + } - override fun loadForRequest(url: HttpUrl) = - cookieManager.getCookie(url.toString())?.split("; ") - ?.mapNotNull { Cookie.parse(url, it) } ?: emptyList() - }).build() + override fun loadForRequest(url: HttpUrl) = + cookieManager.getCookie(url.toString())?.split("; ") + ?.mapNotNull { Cookie.parse(url, it) } ?: emptyList() + }, + ).build() override fun headersBuilder() = Headers.Builder() .set("Accept-Language", langCode) @@ -85,8 +87,11 @@ open class Comico( paginate("all_comic/ranking/trending", page) override fun searchMangaRequest(page: Int, query: String, filters: FilterList) = - if (query.isEmpty()) paginate("all_comic/read_for_free", page) - else POST("$apiUrl/search", apiHeaders, search(query, page)) + if (query.isEmpty()) { + paginate("all_comic/read_for_free", page) + } else { + POST("$apiUrl/search", apiHeaders, search(query, page)) + } override fun chapterListRequest(manga: SManga) = GET(apiUrl + manga.url + "/episode", apiHeaders) @@ -151,8 +156,11 @@ open class Comico( rx.Observable.just(manga.apply { initialized = true })!! override fun fetchPageList(chapter: SChapter) = - if (!chapter.name.endsWith(LOCK)) super.fetchPageList(chapter) - else throw Error("You are not authorized to view this!") + if (!chapter.name.endsWith(LOCK)) { + super.fetchPageList(chapter) + } else { + throw Error("You are not authorized to view this!") + } private fun search(query: String, page: Int) = FormBody.Builder().add("query", query) @@ -176,7 +184,7 @@ open class Comico( private inline fun JsonElement?.map( key: String, - transform: (T) -> R + transform: (T) -> R, ) = json.decodeFromJsonElement>(this[key]).map(transform) override fun mangaDetailsParse(response: Response) = diff --git a/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/ComicoFactory.kt b/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/ComicoFactory.kt index a76b390ca..69fb5d729 100644 --- a/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/ComicoFactory.kt +++ b/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/ComicoFactory.kt @@ -14,6 +14,6 @@ class ComicoFactory : SourceFactory { PocketComics("en-US"), PocketComics("zh-TW"), ComicoJP(), - ComicoKR() + ComicoKR(), ) } diff --git a/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/ComicoModels.kt b/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/ComicoModels.kt index 13143018c..2ce66936c 100644 --- a/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/ComicoModels.kt +++ b/src/all/comico/src/eu/kanade/tachiyomi/extension/all/comico/ComicoModels.kt @@ -52,7 +52,7 @@ data class Chapter( val publishedAt: String, private val salesConfig: SalesConfig, private val hasTrial: Boolean, - private val activity: Activity + private val activity: Activity, ) { val isAvailable: Boolean get() = salesConfig.free || hasTrial || activity.owned @@ -71,5 +71,5 @@ data class Activity(val rented: Boolean, val unlocked: Boolean) { data class ChapterImage( val sort: Int, val url: String, - val parameter: String + val parameter: String, ) diff --git a/src/all/commitstrip/src/eu/kanade/tachiyomi/extension/all/commitstrip/CommitStrip.kt b/src/all/commitstrip/src/eu/kanade/tachiyomi/extension/all/commitstrip/CommitStrip.kt index ea7a5b783..b2f56289b 100644 --- a/src/all/commitstrip/src/eu/kanade/tachiyomi/extension/all/commitstrip/CommitStrip.kt +++ b/src/all/commitstrip/src/eu/kanade/tachiyomi/extension/all/commitstrip/CommitStrip.kt @@ -19,7 +19,7 @@ import java.util.Locale abstract class CommitStrip( override val lang: String, - private val siteLang: String + private val siteLang: String, ) : ParsedHttpSource() { override val name = "Commit Strip" @@ -72,7 +72,7 @@ abstract class CommitStrip( override fun fetchMangaDetails(manga: SManga) = Observable.just( manga.apply { initialized = true - } + }, )!! // Open in WebView diff --git a/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/Cubari.kt b/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/Cubari.kt index 965022b30..29443c7f9 100644 --- a/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/Cubari.kt +++ b/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/Cubari.kt @@ -43,7 +43,7 @@ open class Cubari(override val lang: String) : HttpSource() { "(Android ${Build.VERSION.RELEASE}; " + "${Build.MANUFACTURER} ${Build.MODEL}) " + "Tachiyomi/${AppInfo.getVersionName()} " + - Build.ID + Build.ID, ) } @@ -380,7 +380,7 @@ open class Cubari(override val lang: String) : HttpSource() { enum class SortType { PINNED, - UNPINNED + UNPINNED, } } } diff --git a/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/CubariFactory.kt b/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/CubariFactory.kt index 00f589e50..c101049e3 100644 --- a/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/CubariFactory.kt +++ b/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/CubariFactory.kt @@ -7,6 +7,6 @@ class CubariFactory : SourceFactory { override fun createSources(): List = listOf( Cubari("en"), Cubari("all"), - Cubari("other") + Cubari("other"), ) } diff --git a/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/RemoteStorageUtils.kt b/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/RemoteStorageUtils.kt index ac47e7b53..ee93b00b0 100644 --- a/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/RemoteStorageUtils.kt +++ b/src/all/cubari/src/eu/kanade/tachiyomi/extension/all/cubari/RemoteStorageUtils.kt @@ -86,7 +86,7 @@ class RemoteStorageUtils { handler.postDelayed( { webView?.destroy() }, - DELAY_MILLIS * (if (transparent) 2 else 1) + DELAY_MILLIS * (if (transparent) 2 else 1), ) return if (transparent) { diff --git a/src/all/dragonball_multiverse/AndroidManifest.xml b/src/all/dragonballmultiverse/AndroidManifest.xml similarity index 100% rename from src/all/dragonball_multiverse/AndroidManifest.xml rename to src/all/dragonballmultiverse/AndroidManifest.xml diff --git a/src/all/dragonball_multiverse/build.gradle b/src/all/dragonballmultiverse/build.gradle similarity index 81% rename from src/all/dragonball_multiverse/build.gradle rename to src/all/dragonballmultiverse/build.gradle index 8b2f0f756..366b66211 100644 --- a/src/all/dragonball_multiverse/build.gradle +++ b/src/all/dragonballmultiverse/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'kotlin-android' ext { extName = 'Dragon Ball Multiverse' - pkgNameSuffix = 'all.dragonball_multiverse' + pkgNameSuffix = 'all.dragonballmultiverse' extClass = '.DbMFactory' extVersionCode = 5 } diff --git a/src/all/dragonball_multiverse/res/mipmap-hdpi/ic_launcher.png b/src/all/dragonballmultiverse/res/mipmap-hdpi/ic_launcher.png similarity index 100% rename from src/all/dragonball_multiverse/res/mipmap-hdpi/ic_launcher.png rename to src/all/dragonballmultiverse/res/mipmap-hdpi/ic_launcher.png diff --git a/src/all/dragonball_multiverse/res/mipmap-mdpi/ic_launcher.png b/src/all/dragonballmultiverse/res/mipmap-mdpi/ic_launcher.png similarity index 100% rename from src/all/dragonball_multiverse/res/mipmap-mdpi/ic_launcher.png rename to src/all/dragonballmultiverse/res/mipmap-mdpi/ic_launcher.png diff --git a/src/all/dragonball_multiverse/res/mipmap-xhdpi/ic_launcher.png b/src/all/dragonballmultiverse/res/mipmap-xhdpi/ic_launcher.png similarity index 100% rename from src/all/dragonball_multiverse/res/mipmap-xhdpi/ic_launcher.png rename to src/all/dragonballmultiverse/res/mipmap-xhdpi/ic_launcher.png diff --git a/src/all/dragonball_multiverse/res/mipmap-xxhdpi/ic_launcher.png b/src/all/dragonballmultiverse/res/mipmap-xxhdpi/ic_launcher.png similarity index 100% rename from src/all/dragonball_multiverse/res/mipmap-xxhdpi/ic_launcher.png rename to src/all/dragonballmultiverse/res/mipmap-xxhdpi/ic_launcher.png diff --git a/src/all/dragonball_multiverse/res/mipmap-xxxhdpi/ic_launcher.png b/src/all/dragonballmultiverse/res/mipmap-xxxhdpi/ic_launcher.png similarity index 100% rename from src/all/dragonball_multiverse/res/mipmap-xxxhdpi/ic_launcher.png rename to src/all/dragonballmultiverse/res/mipmap-xxxhdpi/ic_launcher.png diff --git a/src/all/dragonball_multiverse/res/web_hi_res_512.png b/src/all/dragonballmultiverse/res/web_hi_res_512.png similarity index 100% rename from src/all/dragonball_multiverse/res/web_hi_res_512.png rename to src/all/dragonballmultiverse/res/web_hi_res_512.png diff --git a/src/all/dragonball_multiverse/src/eu/kanade/tachiyomi/extension/all/dragonball_multiverse/DbMFactory.kt b/src/all/dragonballmultiverse/src/eu/kanade/tachiyomi/extension/all/dragonballmultiverse/DbMFactory.kt similarity index 97% rename from src/all/dragonball_multiverse/src/eu/kanade/tachiyomi/extension/all/dragonball_multiverse/DbMFactory.kt rename to src/all/dragonballmultiverse/src/eu/kanade/tachiyomi/extension/all/dragonballmultiverse/DbMFactory.kt index 1a8a44819..5b7076550 100644 --- a/src/all/dragonball_multiverse/src/eu/kanade/tachiyomi/extension/all/dragonball_multiverse/DbMFactory.kt +++ b/src/all/dragonballmultiverse/src/eu/kanade/tachiyomi/extension/all/dragonballmultiverse/DbMFactory.kt @@ -1,6 +1,6 @@ @file:Suppress("ClassName") -package eu.kanade.tachiyomi.extension.all.dragonball_multiverse +package eu.kanade.tachiyomi.extension.all.dragonballmultiverse import eu.kanade.tachiyomi.source.Source import eu.kanade.tachiyomi.source.SourceFactory @@ -43,7 +43,7 @@ class DbMFactory : SourceFactory { DbMultiverseCO_FR(), DbMultiverseBR_FR(), DbMultiverseXX_VE(), - DbMultiverseXX_LMO() + DbMultiverseXX_LMO(), ) } diff --git a/src/all/dragonball_multiverse/src/eu/kanade/tachiyomi/extension/all/dragonball_multiverse/DbMultiverse.kt b/src/all/dragonballmultiverse/src/eu/kanade/tachiyomi/extension/all/dragonballmultiverse/DbMultiverse.kt similarity index 94% rename from src/all/dragonball_multiverse/src/eu/kanade/tachiyomi/extension/all/dragonball_multiverse/DbMultiverse.kt rename to src/all/dragonballmultiverse/src/eu/kanade/tachiyomi/extension/all/dragonballmultiverse/DbMultiverse.kt index 5b0955681..af4233dd3 100644 --- a/src/all/dragonball_multiverse/src/eu/kanade/tachiyomi/extension/all/dragonball_multiverse/DbMultiverse.kt +++ b/src/all/dragonballmultiverse/src/eu/kanade/tachiyomi/extension/all/dragonballmultiverse/DbMultiverse.kt @@ -1,4 +1,4 @@ -package eu.kanade.tachiyomi.extension.all.dragonball_multiverse +package eu.kanade.tachiyomi.extension.all.dragonballmultiverse import eu.kanade.tachiyomi.source.model.FilterList import eu.kanade.tachiyomi.source.model.MangasPage @@ -15,8 +15,11 @@ import rx.Observable abstract class DbMultiverse(override val lang: String, private val internalLang: String) : ParsedHttpSource() { override val name = - if (internalLang.endsWith("_PA")) "Dragon Ball Multiverse Parody" - else "Dragon Ball Multiverse" + if (internalLang.endsWith("_PA")) { + "Dragon Ball Multiverse Parody" + } else { + "Dragon Ball Multiverse" + } override val baseUrl = "https://www.dragonball-multiverse.com" override val supportsLatest = false diff --git a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHFactory.kt b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHFactory.kt index 2ab1deca7..91dfd40e2 100644 --- a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHFactory.kt +++ b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHFactory.kt @@ -21,7 +21,7 @@ class EHFactory : SourceFactory { EHentaiTh(), EHentaiVi(), EHentaiNone(), - EHentaiOther() + EHentaiOther(), ) } diff --git a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHUtil.kt b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHUtil.kt index 8db29e4ce..2fe4b7ad5 100644 --- a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHUtil.kt +++ b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHUtil.kt @@ -11,10 +11,11 @@ import kotlin.math.pow * Return null if String is blank, otherwise returns the original String * @returns null if the String is blank, otherwise returns the original String */ -fun String?.nullIfBlank(): String? = if (isNullOrBlank()) +fun String?.nullIfBlank(): String? = if (isNullOrBlank()) { null -else +} else { this +} /** * Ignores any exceptions thrown inside a block diff --git a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHentai.kt b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHentai.kt index 9f0b9e4bf..7e7cf1548 100644 --- a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHentai.kt +++ b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/EHentai.kt @@ -36,7 +36,7 @@ import java.net.URLEncoder abstract class EHentai( override val lang: String, - private val ehLang: String + private val ehLang: String, ) : ConfigurableSource, HttpSource() { private val preferences: SharedPreferences by lazy { @@ -102,8 +102,8 @@ abstract class EHentai( url = manga.url name = "Chapter" chapter_number = 1f - } - ) + }, + ), ) override fun fetchPageList(chapter: SChapter) = fetchChapterPage(chapter, "$baseUrl/${chapter.url}").map { @@ -118,7 +118,7 @@ abstract class EHentai( private fun fetchChapterPage( chapter: SChapter, np: String, - pastUrls: List = emptyList() + pastUrls: List = emptyList(), ): Observable> { val urls = ArrayList(pastUrls) return chapterPageCall(np).flatMap { @@ -210,7 +210,7 @@ abstract class EHentai( } } headers.build() - } ?: headers + } ?: headers, ).let { if (!cache) { @@ -294,7 +294,7 @@ abstract class EHentai( val currentTags = it.select("div").map { element -> Tag( element.text().trim(), - element.hasClass("gtl") + element.hasClass("gtl"), ) } tags[namespace] = currentTags @@ -391,13 +391,14 @@ abstract class EHentai( TagFilter("Misc Tags", triStateBoxesFrom(miscTags), "other"), TagFilter("Female Tags", triStateBoxesFrom(femaleTags), "female"), TagFilter("Male Tags", triStateBoxesFrom(maleTags), "male"), - AdvancedGroup() + AdvancedGroup(), ) class Watched : CheckBox("Watched List"), UriFilter { override fun addToUri(builder: Uri.Builder) { - if (state) + if (state) { builder.appendPath("watched") + } } } @@ -419,14 +420,15 @@ abstract class EHentai( GenreOption("Image Set", "imageset"), GenreOption("Cosplay", "cosplay"), GenreOption("Asian Porn", "asianporn"), - GenreOption("Misc", "misc") - ) + GenreOption("Misc", "misc"), + ), ) class AdvancedOption(name: String, private val param: String, defValue: Boolean = false) : CheckBox(name, defValue), UriFilter { override fun addToUri(builder: Uri.Builder) { - if (state) + if (state) { builder.appendQueryParameter(param, "on") + } } } @@ -453,8 +455,8 @@ abstract class EHentai( "2 stars", "3 stars", "4 stars", - "5 stars" - ) + "5 stars", + ), ), UriFilter { override fun addToUri(builder: Uri.Builder) { @@ -479,8 +481,8 @@ abstract class EHentai( AdvancedOption("Show Expunged Galleries", "f_sh"), RatingOption(), MinPagesOption(), - MaxPagesOption() - ) + MaxPagesOption(), + ), ) private class EnforceLanguageFilter(default: Boolean) : CheckBox("Enforce language", default) @@ -514,7 +516,7 @@ abstract class EHentai( Pair("thai", listOf("120", "1144", "2168")), Pair("vietnamese", listOf("130", "1154", "2178")), Pair("n/a", listOf("254", "1278", "2302")), - Pair("other", listOf("255", "1279", "2303")) + Pair("other", listOf("255", "1279", "2303")), ) companion object { diff --git a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/ExGalleryMetadata.kt b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/ExGalleryMetadata.kt index 5730a33a3..92fa7fea3 100644 --- a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/ExGalleryMetadata.kt +++ b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/ExGalleryMetadata.kt @@ -34,10 +34,11 @@ class ExGalleryMetadata { companion object { private fun splitGalleryUrl(url: String) = url.let { // Only parse URL if is full URL - val pathSegments = if (it.startsWith("http")) + val pathSegments = if (it.startsWith("http")) { Uri.parse(it).pathSegments - else + } else { it.split('/') + } pathSegments.filterNot(String::isNullOrBlank) } diff --git a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/MetadataCopier.kt b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/MetadataCopier.kt index fef785b69..cf7e0e8c4 100644 --- a/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/MetadataCopier.kt +++ b/src/all/ehentai/src/eu/kanade/tachiyomi/extension/all/ehentai/MetadataCopier.kt @@ -11,7 +11,7 @@ private const val EH_AUTHOR_NAMESPACE = "author" private val ONGOING_SUFFIX = arrayOf( "[ongoing]", "(ongoing)", - "{ongoing}" + "{ongoing}", ) val EX_DATE_FORMAT = SimpleDateFormat("yyyy-MM-dd HH:mm", Locale.US) @@ -40,7 +40,9 @@ fun ExGalleryMetadata.copyTo(manga: SManga) { if (ONGOING_SUFFIX.any { t.endsWith(it, ignoreCase = true) } - ) manga.status = SManga.ONGOING + ) { + manga.status = SManga.ONGOING + } } // Build a nice looking description out of what we know diff --git a/src/all/everiaclub/src/eu/kanade/tachiyomi/extension/all/everiaclub/EveriaClub.kt b/src/all/everiaclub/src/eu/kanade/tachiyomi/extension/all/everiaclub/EveriaClub.kt index 5f34faf01..16c6bae55 100644 --- a/src/all/everiaclub/src/eu/kanade/tachiyomi/extension/all/everiaclub/EveriaClub.kt +++ b/src/all/everiaclub/src/eu/kanade/tachiyomi/extension/all/everiaclub/EveriaClub.kt @@ -124,7 +124,7 @@ class EveriaClub() : ParsedHttpSource() { open class UriPartFilter( displayName: String, - private val valuePair: Array> + private val valuePair: Array>, ) : Filter.Select(displayName, valuePair.map { it.first }.toTypedArray()) { fun toUriPart() = valuePair[state].second } @@ -140,7 +140,7 @@ class EveriaClub() : ParsedHttpSource() { Pair("Thailand", "/thailand"), Pair("Chinese", "/chinese"), Pair("Cosplay", "/cosplay"), - ) + ), ) class TagFilter : Filter.Text("Tag") diff --git a/src/all/hennojin/src/eu/kanade/tachiyomi/extension/all/hennojin/Hennojin.kt b/src/all/hennojin/src/eu/kanade/tachiyomi/extension/all/hennojin/Hennojin.kt index b46c27fea..856b04b54 100644 --- a/src/all/hennojin/src/eu/kanade/tachiyomi/extension/all/hennojin/Hennojin.kt +++ b/src/all/hennojin/src/eu/kanade/tachiyomi/extension/all/hennojin/Hennojin.kt @@ -72,18 +72,18 @@ class Hennojin(override val lang: String, suffix: String) : ParsedHttpSource() { override fun mangaDetailsParse(document: Document) = SManga.create().apply { description = document.selectFirst( - ".manga-subtitle + p + p" + ".manga-subtitle + p + p", )?.html()?.replace("
", "\n") genre = document.select( ".tags-list a[href*=/parody/]," + ".tags-list a[href*=/tags/]," + - ".tags-list a[href*=/character/]" + ".tags-list a[href*=/character/]", )?.joinToString { it.text() } artist = document.select( - ".tags-list a[href*=/artist/]" + ".tags-list a[href*=/artist/]", )?.joinToString { it.text() } author = document.select( - ".tags-list a[href*=/group/]" + ".tags-list a[href*=/group/]", )?.joinToString { it.text() } ?: artist status = SManga.COMPLETED } @@ -108,7 +108,7 @@ class Hennojin(override val lang: String, suffix: String) : ParsedHttpSource() { .mapIndexed { idx, img -> Page(idx, "", img.absUrl("src")) } private inline fun HttpUrl.request( - block: HttpUrl.Builder.() -> HttpUrl.Builder + block: HttpUrl.Builder.() -> HttpUrl.Builder, ) = GET(newBuilder().block().toString(), headers) private inline val Response.date: Long diff --git a/src/all/hennojin/src/eu/kanade/tachiyomi/extension/all/hennojin/HennojinFactory.kt b/src/all/hennojin/src/eu/kanade/tachiyomi/extension/all/hennojin/HennojinFactory.kt index 7b1da024c..3ebf6fe62 100644 --- a/src/all/hennojin/src/eu/kanade/tachiyomi/extension/all/hennojin/HennojinFactory.kt +++ b/src/all/hennojin/src/eu/kanade/tachiyomi/extension/all/hennojin/HennojinFactory.kt @@ -5,6 +5,6 @@ import eu.kanade.tachiyomi.source.SourceFactory class HennojinFactory : SourceFactory { override fun createSources() = listOf( Hennojin("en", ""), - Hennojin("ja", "?archive=raw") + Hennojin("ja", "?archive=raw"), ) } diff --git a/src/all/imhentai/src/eu/kanade/tachiyomi/extension/all/imhentai/IMHentai.kt b/src/all/imhentai/src/eu/kanade/tachiyomi/extension/all/imhentai/IMHentai.kt index 3e9941e11..47853de46 100644 --- a/src/all/imhentai/src/eu/kanade/tachiyomi/extension/all/imhentai/IMHentai.kt +++ b/src/all/imhentai/src/eu/kanade/tachiyomi/extension/all/imhentai/IMHentai.kt @@ -47,7 +47,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH return response.newBuilder() .body(responseString.toResponseBody(responseContentType)) .build() - } + }, ).build() // Popular @@ -143,7 +143,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH it.ownText(), it.select(".split_tag")?.text() ?.trim() - ?.removePrefix("| ") + ?.removePrefix("| "), ) .filter { s -> !s.isNullOrBlank() } .joinToString(splitTagSeparator) @@ -151,7 +151,6 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH } override fun mangaDetailsParse(document: Document): SManga = SManga.create().apply { - title = document.selectFirst("div.right_details > h1").text() thumbnail_url = document.selectFirst("div.left_cover img")?.let { @@ -179,7 +178,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH "Characters", "Groups", "Languages", - "Category" + "Category", ).map { it to infoMap[it]?.csvText() } .let { listOf(Pair("Alternate Title", altTitle)) + it + listOf(Pair("Pages", pages)) } .filter { !it.second.isNullOrEmpty() } @@ -194,7 +193,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH setUrlWithoutDomain(response.request.url.toString().replace("gallery", "view") + "1") name = "Chapter" chapter_number = 1f - } + }, ) } @@ -223,7 +222,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH val images = json.parseToJsonElement( document.selectFirst("script:containsData(var g_th)").data() - .substringAfter("$.parseJSON('").substringBefore("');").trim() + .substringAfter("$.parseJSON('").substringBefore("');").trim(), ).jsonObject val pages = mutableListOf() @@ -257,7 +256,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH private fun getFilterList(sortOrderState: Int) = FilterList( SortOrderFilter(getSortOrderURIs(), sortOrderState), CategoryFilters(getCategoryURIs()), - LanguageFilters(getLanguageURIs().filter { it.name != imhLang }) // exclude main lang + LanguageFilters(getLanguageURIs().filter { it.name != imhLang }), // exclude main lang ) private fun getCategoryURIs() = listOf( @@ -266,7 +265,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH SearchFlagFilter("Western", "western"), SearchFlagFilter("Image Set", "imageset"), SearchFlagFilter("Artist CG", "artistcg"), - SearchFlagFilter("Game CG", "gamecg") + SearchFlagFilter("Game CG", "gamecg"), ) // update sort order indices in companion object if order is changed @@ -274,7 +273,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH Pair("Popular", "pp"), Pair("Latest", "lt"), Pair("Downloads", "dl"), - Pair("Top Rated", "tr") + Pair("Top Rated", "tr"), ) private fun getLanguageURIs() = listOf( @@ -284,7 +283,7 @@ class IMHentai(override val lang: String, private val imhLang: String) : ParsedH LanguageFilter(LANGUAGE_FRENCH, "fr"), LanguageFilter(LANGUAGE_KOREAN, "kr"), LanguageFilter(LANGUAGE_GERMAN, "de"), - LanguageFilter(LANGUAGE_RUSSIAN, "ru") + LanguageFilter(LANGUAGE_RUSSIAN, "ru"), ) private fun getLanguageURIByName(name: String): LanguageFilter { diff --git a/src/all/imhentai/src/eu/kanade/tachiyomi/extension/all/imhentai/IMHentaiFactory.kt b/src/all/imhentai/src/eu/kanade/tachiyomi/extension/all/imhentai/IMHentaiFactory.kt index 5d26ed661..b6b7add53 100644 --- a/src/all/imhentai/src/eu/kanade/tachiyomi/extension/all/imhentai/IMHentaiFactory.kt +++ b/src/all/imhentai/src/eu/kanade/tachiyomi/extension/all/imhentai/IMHentaiFactory.kt @@ -12,6 +12,6 @@ class IMHentaiFactory : SourceFactory { IMHentai("fr", IMHentai.LANGUAGE_FRENCH), IMHentai("ko", IMHentai.LANGUAGE_KOREAN), IMHentai("de", IMHentai.LANGUAGE_GERMAN), - IMHentai("ru", IMHentai.LANGUAGE_RUSSIAN) + IMHentai("ru", IMHentai.LANGUAGE_RUSSIAN), ) } diff --git a/src/all/izneo/src/eu/kanade/tachiyomi/extension/all/izneo/ImageInterceptor.kt b/src/all/izneo/src/eu/kanade/tachiyomi/extension/all/izneo/ImageInterceptor.kt index 0aeafbc82..e0fe34c50 100644 --- a/src/all/izneo/src/eu/kanade/tachiyomi/extension/all/izneo/ImageInterceptor.kt +++ b/src/all/izneo/src/eu/kanade/tachiyomi/extension/all/izneo/ImageInterceptor.kt @@ -24,8 +24,8 @@ object ImageInterceptor : Interceptor { url.newBuilder() .removeAllQueryParameters("key") .removeAllQueryParameters("iv") - .build() - ).build() + .build(), + ).build(), ).decode(key.atob(), url.queryParameter("iv")!!.atob()) } diff --git a/src/all/izneo/src/eu/kanade/tachiyomi/extension/all/izneo/IzneoAPI.kt b/src/all/izneo/src/eu/kanade/tachiyomi/extension/all/izneo/IzneoAPI.kt index a56076b4f..8f2e0ca1a 100644 --- a/src/all/izneo/src/eu/kanade/tachiyomi/extension/all/izneo/IzneoAPI.kt +++ b/src/all/izneo/src/eu/kanade/tachiyomi/extension/all/izneo/IzneoAPI.kt @@ -11,7 +11,7 @@ data class Series( private val synopsis: String, private val gender: String, private val target: Target, - val authors: List + val authors: List, ) { val genres: String get() = "$gender, $target" @@ -41,7 +41,7 @@ data class Album( val publicationDate: String, private val fullAvailable: Boolean, private val inUserLibrary: Boolean, - private val inUserSubscription: Boolean + private val inUserSubscription: Boolean, ) { val number: Float get() = volume.toFloat() @@ -57,7 +57,7 @@ data class Album( data class AlbumPage( val albumPageNumber: Int, private val key: String, - private val iv: String + private val iv: String, ) { override fun toString() = "/$albumPageNumber?type=full&key=${key.urlSafe}&iv=${iv.urlSafe}" diff --git a/src/all/junmeitu/src/eu/kanade/tachiyomi/extension/all/junmeitu/Junmeitu.kt b/src/all/junmeitu/src/eu/kanade/tachiyomi/extension/all/junmeitu/Junmeitu.kt index 7154cba11..1464fe64e 100644 --- a/src/all/junmeitu/src/eu/kanade/tachiyomi/extension/all/junmeitu/Junmeitu.kt +++ b/src/all/junmeitu/src/eu/kanade/tachiyomi/extension/all/junmeitu/Junmeitu.kt @@ -141,7 +141,7 @@ class Junmeitu : ParsedHttpSource() { ModelFilter(), GroupFilter(), CategoryFilter(getCategoryFilter(), 0), - SortFilter(getSortFilter(), 0) + SortFilter(getSortFilter(), 0), ) class SelectFilterOption(val name: String, val value: String = name) diff --git a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/Kavita.kt b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/Kavita.kt index b01fba0b4..97caf0b34 100644 --- a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/Kavita.kt +++ b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/Kavita.kt @@ -71,7 +71,9 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou // Both are volumes, multiply by 100 and do normal sort return if ((a.chapter_number * 100) < (b.chapter_number * 100)) { 1 - } else -1 + } else { + -1 + } } else { if (a.chapter_number < 1.0 && b.chapter_number >= 1.0) { // A is volume, b is not. A should sort first @@ -121,7 +123,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.e(LOG_TAG, "Empty body String for request url: ${it.request.url}") throw EmptyRequestBody( "Body of the response is empty. RequestUrl=${it.request.url}\nPlease check your kavita instance is up to date", - Throwable("Error. Request body is empty") + Throwable("Error. Request body is empty"), ) } json.decodeFromString(it.body?.string().orEmpty()) @@ -139,7 +141,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou return POST( "$apiUrl/series/all?pageNumber=$page&libraryId=0&pageSize=20", headersBuilder().build(), - buildFilterBody(currentFilter) + buildFilterBody(currentFilter), ) } @@ -162,7 +164,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou return POST( "$apiUrl/series/all?pageNumber=$page&libraryId=0&pageSize=20", headersBuilder().build(), - buildFilterBody(MetadataPayload(sorting = 4, sorting_asc = false, forceUseMetadataPayload = true)) + buildFilterBody(MetadataPayload(sorting = 4, sorting_asc = false, forceUseMetadataPayload = true)), ) } @@ -179,7 +181,6 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou val newFilter = MetadataPayload() // need to reset it or will double filters.forEach { filter -> when (filter) { - is SortFilter -> { if (filter.state != null) { newFilter.sorting = filter.state!!.index + 1 @@ -196,10 +197,12 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou is ReleaseYearRangeGroup -> { filter.state.forEach { content -> if (content.state.isNotEmpty()) { - if (content.name == "Min") + if (content.name == "Min") { newFilter.releaseYearRangeMin = content.state.toInt() - if (content.name == "Max") + } + if (content.name == "Max") { newFilter.releaseYearRangeMax = content.state.toInt() + } } } } @@ -366,12 +369,11 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou val foundSerie = series.find { dto -> dto.id == serieId } return GET( "$baseUrl/library/${foundSerie!!.libraryId}/series/$serieId", - headersBuilder().build() + headersBuilder().build(), ) } override fun mangaDetailsParse(response: Response): SManga { - val result = response.parseAs() val existingSeries = series.find { dto -> dto.id == result.seriesId } @@ -502,8 +504,8 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou pages.add( Page( index = i, - imageUrl = "$apiUrl/Reader/image?chapterId=$chapterId&page=$i&extractPdf=true" - ) + imageUrl = "$apiUrl/Reader/image?chapterId=$chapterId&page=$i&extractPdf=true", + ), ) } return Observable.just(pages) @@ -537,7 +539,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou "Editor", "Publisher", "Character", - "Translator" + "Translator", ) private class UserRating : @@ -549,8 +551,8 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou "2 stars", "3 stars", "4 stars", - "5 stars" - ) + "5 stars", + ), ) private class SortFilter(sortables: Array) : Filter.Sort("Sort by", sortables, Selection(0, true)) @@ -560,7 +562,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Pair("Created", 2), Pair("Last modified", 3), Pair("Item added", 4), - Pair("Time to Read", 5) + Pair("Time to Read", 5), ) private class StatusFilter(name: String) : Filter.CheckBox(name, false) @@ -665,7 +667,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou if (sortableList.isNotEmpty() and toggledFilters.contains("Sort Options")) { filtersLoaded.add( - SortFilter(sortableList.map { it.first }.toTypedArray()) + SortFilter(sortableList.map { it.first }.toTypedArray()), ) } if (toggledFilters.contains("Read Status")) { @@ -674,32 +676,32 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou listOf( "notRead", "inProgress", - "read" - ).map { StatusFilter(it) } - ) + "read", + ).map { StatusFilter(it) }, + ), ) } if (toggledFilters.contains("ReleaseYearRange")) { filtersLoaded.add( ReleaseYearRangeGroup( - listOf("Min", "Max").map { ReleaseYearRange(it) } - ) + listOf("Min", "Max").map { ReleaseYearRange(it) }, + ), ) } if (genresListMeta.isNotEmpty() and toggledFilters.contains("Genres")) { filtersLoaded.add( - GenreFilterGroup(genresListMeta.map { GenreFilter(it.title) }) + GenreFilterGroup(genresListMeta.map { GenreFilter(it.title) }), ) } if (tagsListMeta.isNotEmpty() and toggledFilters.contains("Tags")) { filtersLoaded.add( - TagFilterGroup(tagsListMeta.map { TagFilter(it.title) }) + TagFilterGroup(tagsListMeta.map { TagFilter(it.title) }), ) } if (ageRatingsListMeta.isNotEmpty() and toggledFilters.contains("Age Rating")) { filtersLoaded.add( - AgeRatingFilterGroup(ageRatingsListMeta.map { AgeRatingFilter(it.title) }) + AgeRatingFilterGroup(ageRatingsListMeta.map { AgeRatingFilter(it.title) }), ) } if (toggledFilters.contains("Format")) { @@ -710,33 +712,33 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou "Archive", "Pdf", "Unknown", - ).map { FormatFilter(it) } - ) + ).map { FormatFilter(it) }, + ), ) } if (collectionsListMeta.isNotEmpty() and toggledFilters.contains("Collections")) { filtersLoaded.add( - CollectionFilterGroup(collectionsListMeta.map { CollectionFilter(it.title) }) + CollectionFilterGroup(collectionsListMeta.map { CollectionFilter(it.title) }), ) } if (languagesListMeta.isNotEmpty() and toggledFilters.contains("Languages")) { filtersLoaded.add( - LanguageFilterGroup(languagesListMeta.map { LanguageFilter(it.title) }) + LanguageFilterGroup(languagesListMeta.map { LanguageFilter(it.title) }), ) } if (libraryListMeta.isNotEmpty() and toggledFilters.contains("Libraries")) { filtersLoaded.add( - LibrariesFilterGroup(libraryListMeta.map { LibraryFilter(it.name) }) + LibrariesFilterGroup(libraryListMeta.map { LibraryFilter(it.name) }), ) } if (pubStatusListMeta.isNotEmpty() and toggledFilters.contains("Publication Status")) { filtersLoaded.add( - PubStatusFilterGroup(pubStatusListMeta.map { PubStatusFilter(it.title) }) + PubStatusFilterGroup(pubStatusListMeta.map { PubStatusFilter(it.title) }), ) } if (pubStatusListMeta.isNotEmpty() and toggledFilters.contains("Rating")) { filtersLoaded.add( - UserRating() + UserRating(), ) } @@ -746,78 +748,78 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou listOf>( PeopleHeaderFilter(""), PeopleSeparatorFilter(), - PeopleHeaderFilter("PEOPLE") - ) + PeopleHeaderFilter("PEOPLE"), + ), ) if (peopleInRoles[0].isNotEmpty() and toggledFilters.contains("Writer")) { filtersLoaded.add( WriterPeopleFilterGroup( - peopleInRoles[0].map { WriterPeopleFilter(it.name) } - ) + peopleInRoles[0].map { WriterPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[1].isNotEmpty() and toggledFilters.contains("Penciller")) { filtersLoaded.add( PencillerPeopleFilterGroup( - peopleInRoles[1].map { PencillerPeopleFilter(it.name) } - ) + peopleInRoles[1].map { PencillerPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[2].isNotEmpty() and toggledFilters.contains("Inker")) { filtersLoaded.add( InkerPeopleFilterGroup( - peopleInRoles[2].map { InkerPeopleFilter(it.name) } - ) + peopleInRoles[2].map { InkerPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[3].isNotEmpty() and toggledFilters.contains("Colorist")) { filtersLoaded.add( ColoristPeopleFilterGroup( - peopleInRoles[3].map { ColoristPeopleFilter(it.name) } - ) + peopleInRoles[3].map { ColoristPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[4].isNotEmpty() and toggledFilters.contains("Letterer")) { filtersLoaded.add( LettererPeopleFilterGroup( - peopleInRoles[4].map { LettererPeopleFilter(it.name) } - ) + peopleInRoles[4].map { LettererPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[5].isNotEmpty() and toggledFilters.contains("CoverArtist")) { filtersLoaded.add( CoverArtistPeopleFilterGroup( - peopleInRoles[5].map { CoverArtistPeopleFilter(it.name) } - ) + peopleInRoles[5].map { CoverArtistPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[6].isNotEmpty() and toggledFilters.contains("Editor")) { filtersLoaded.add( EditorPeopleFilterGroup( - peopleInRoles[6].map { EditorPeopleFilter(it.name) } - ) + peopleInRoles[6].map { EditorPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[7].isNotEmpty() and toggledFilters.contains("Publisher")) { filtersLoaded.add( PublisherPeopleFilterGroup( - peopleInRoles[7].map { PublisherPeopleFilter(it.name) } - ) + peopleInRoles[7].map { PublisherPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[8].isNotEmpty() and toggledFilters.contains("Character")) { filtersLoaded.add( CharacterPeopleFilterGroup( - peopleInRoles[8].map { CharacterPeopleFilter(it.name) } - ) + peopleInRoles[8].map { CharacterPeopleFilter(it.name) }, + ), ) } if (peopleInRoles[9].isNotEmpty() and toggledFilters.contains("Translator")) { filtersLoaded.add( TranslatorPeopleFilterGroup( - peopleInRoles[9].map { TranslatorPeopleFilter(it.name) } - ) + peopleInRoles[9].map { TranslatorPeopleFilter(it.name) }, + ), ) filtersLoaded } else { @@ -866,7 +868,6 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou .add("Authorization", "Bearer $jwtToken") } private fun buildFilterBody(filter: MetadataPayload): RequestBody { - val formats = if (filter.formats.isEmpty()) { buildJsonArray { add(MangaFormat.Archive.ordinal) @@ -891,7 +892,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou put("inProgress", JsonPrimitive(true)) put("read", JsonPrimitive(true)) } - } + }, ) put("genres", buildJsonArray { filter.genres.map { add(it) } }) put("writers", buildJsonArray { filter.peopleWriters.map { add(it) } }) @@ -915,7 +916,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou buildJsonObject { put("sortField", filter.sorting) put("isAscending", JsonPrimitive(filter.sorting_asc)) - } + }, ) put("seriesNameQuery", filter.seriesNameQuery) put( @@ -923,7 +924,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou buildJsonObject { put("min", filter.releaseYearRangeMin) put("max", filter.releaseYearRangeMax) - } + }, ) } return payload.toString().toRequestBody(JSON_MEDIA_TYPE) @@ -934,7 +935,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou ADDRESS_TITLE, "OPDS url", "", - "The OPDS url copied from User Settings. This should include address and the api key on end." + "The OPDS url copied from User Settings. This should include address and the api key on end.", ) val enabledFiltersPref = MultiSelectListPreference(screen.context).apply { key = KavitaConstants.toggledFiltersPref @@ -963,7 +964,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Toast.makeText( screen.context, "Restart Tachiyomi to apply new setting.", - Toast.LENGTH_LONG + Toast.LENGTH_LONG, ).show() Log.v(LOG_TAG, "[Preferences] Successfully modified custom source name: $newValue") res @@ -979,7 +980,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou title: String, default: String, summary: String, - isPassword: Boolean = false + isPassword: Boolean = false, ): EditTextPreference { return EditTextPreference(context).apply { key = preKey @@ -1005,7 +1006,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Toast.makeText( context, "URL exists in a different source -> $opdsUrlInPref", - Toast.LENGTH_LONG + Toast.LENGTH_LONG, ).show() throw OpdsurlExistsInPref("Url exists in a different source -> $opdsUrlInPref") } @@ -1014,7 +1015,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Toast.makeText( context, "Restart Tachiyomi to apply new setting.", - Toast.LENGTH_LONG + Toast.LENGTH_LONG, ).show() setupLogin(newValue) Log.v(LOG_TAG, "[Preferences] Successfully modified OPDS URL") @@ -1098,7 +1099,6 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } private fun doLogin() { - if (address.isEmpty()) { Log.e(LOG_TAG, "OPDS URL is empty or null") throw IOException("You must setup the Address to communicate with Kavita") @@ -1110,7 +1110,8 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.v(LOG_TAG, "[Login] Starting login") val request = POST( "$apiUrl/Plugin/authenticate?apiKey=${getPrefKey()}&pluginName=Tachiyomi-Kavita", - setupLoginHeaders().build(), "{}".toRequestBody("application/json; charset=utf-8".toMediaTypeOrNull()) + setupLoginHeaders().build(), + "{}".toRequestBody("application/json; charset=utf-8".toMediaTypeOrNull()), ) client.newCall(request).execute().use { val peekbody = it.peekBody(Long.MAX_VALUE).toString() @@ -1149,7 +1150,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.e( LOG_TAG, "Extension version: code=${AppInfo.getVersionCode()} name=${AppInfo.getVersionName()}" + - " - - Kavita version: ${serverInfoDto.kavitaVersion}" + " - - Kavita version: ${serverInfoDto.kavitaVersion}", ) // this is not a real error. Using this so it gets printed in dump logs if there's any error } catch (e: EmptyRequestBody) { Log.e(LOG_TAG, "Extension version: code=${AppInfo.getVersionCode()} - name=${AppInfo.getVersionName()}") @@ -1169,7 +1170,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } else { Log.e( LOG_TAG, - "[Filter] Error decoding JSON for genres filter: response body is null. Response code: ${response.code}" + "[Filter] Error decoding JSON for genres filter: response body is null. Response code: ${response.code}", ) emptyList() } @@ -1188,7 +1189,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } else { Log.e( LOG_TAG, - "[Filter] Error decoding JSON for tagsList filter: response body is null. Response code: ${response.code}" + "[Filter] Error decoding JSON for tagsList filter: response body is null. Response code: ${response.code}", ) emptyList() } @@ -1207,7 +1208,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } else { Log.e( LOG_TAG, - "[Filter] Error decoding JSON for age-ratings filter: response body is null. Response code: ${response.code}" + "[Filter] Error decoding JSON for age-ratings filter: response body is null. Response code: ${response.code}", ) emptyList() } @@ -1215,7 +1216,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.e( LOG_TAG, "[Filter] Error decoding JSON for age-ratings filter", - e + e, ) emptyList() } @@ -1230,7 +1231,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } else { Log.e( LOG_TAG, - "[Filter] Error decoding JSON for collectionsListMeta filter: response body is null. Response code: ${response.code}" + "[Filter] Error decoding JSON for collectionsListMeta filter: response body is null. Response code: ${response.code}", ) emptyList() } @@ -1238,7 +1239,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.e( LOG_TAG, "[Filter] Error decoding JSON for collectionsListMeta filter", - e + e, ) emptyList() } @@ -1253,7 +1254,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } else { Log.e( LOG_TAG, - "[Filter] Error decoding JSON for languagesListMeta filter: response body is null. Response code: ${response.code}" + "[Filter] Error decoding JSON for languagesListMeta filter: response body is null. Response code: ${response.code}", ) emptyList() } @@ -1261,7 +1262,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.e( LOG_TAG, "[Filter] Error decoding JSON for languagesListMeta filter", - e + e, ) emptyList() } @@ -1276,7 +1277,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } else { Log.e( LOG_TAG, - "[Filter] Error decoding JSON for libraries filter: response body is null. Response code: ${response.code}" + "[Filter] Error decoding JSON for libraries filter: response body is null. Response code: ${response.code}", ) emptyList() } @@ -1284,7 +1285,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.e( LOG_TAG, "[Filter] Error decoding JSON for libraries filter", - e + e, ) emptyList() } @@ -1299,7 +1300,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } else { Log.e( LOG_TAG, - "error while decoding JSON for peopleListMeta filter: response body is null. Response code: ${response.code}" + "error while decoding JSON for peopleListMeta filter: response body is null. Response code: ${response.code}", ) emptyList() } @@ -1307,7 +1308,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.e( LOG_TAG, "error while decoding JSON for peopleListMeta filter", - e + e, ) emptyList() } @@ -1321,7 +1322,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou } else { Log.e( LOG_TAG, - "error while decoding JSON for publicationStatusListMeta filter: response body is null. Response code: ${response.code}" + "error while decoding JSON for publicationStatusListMeta filter: response body is null. Response code: ${response.code}", ) emptyList() } @@ -1329,7 +1330,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou Log.e( LOG_TAG, "error while decoding JSON for publicationStatusListMeta filter", - e + e, ) emptyList() } @@ -1356,7 +1357,7 @@ class Kavita(private val suffix: String = "") : ConfigurableSource, UnmeteredSou return@subscribe } Log.e(LOG_TAG, "error while doing initial calls", tr) - } + }, ) } } diff --git a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/KavitaConstants.kt b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/KavitaConstants.kt index f385510c0..036c35b75 100644 --- a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/KavitaConstants.kt +++ b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/KavitaConstants.kt @@ -25,7 +25,7 @@ object KavitaConstants { "Publisher", "Character", "Translators", - "ReleaseYearRange" + "ReleaseYearRange", ) val filterPrefEntriesValue = arrayOf( "Sort Options", @@ -49,7 +49,7 @@ object KavitaConstants { "Publisher", "Character", "Translators", - "ReleaseYearRange" + "ReleaseYearRange", ) val defaultFilterPrefEntries = setOf( "Sort Options", @@ -73,7 +73,7 @@ object KavitaConstants { "Publisher", "Character", "Translators", - "ReleaseYearRange" + "ReleaseYearRange", ) const val customSourceNamePref = "customSourceName" diff --git a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/KavitaFactory.kt b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/KavitaFactory.kt index c709140d7..7639b6e53 100644 --- a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/KavitaFactory.kt +++ b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/KavitaFactory.kt @@ -8,6 +8,6 @@ class KavitaFactory : SourceFactory { listOf( Kavita("1"), Kavita("2"), - Kavita("3") + Kavita("3"), ) } diff --git a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/MangaDto.kt b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/MangaDto.kt index c948b4be2..587a425e7 100644 --- a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/MangaDto.kt +++ b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/MangaDto.kt @@ -8,7 +8,8 @@ enum class MangaFormat(val format: Int) { Archive(1), Unknown(2), Epub(3), - Pdf(4); + Pdf(4), + ; companion object { private val map = PersonRole.values().associateBy(PersonRole::role) fun fromInt(type: Int) = map[type] @@ -25,12 +26,14 @@ enum class PersonRole(val role: Int) { Editor(9), Publisher(10), Character(11), - Translator(12); + Translator(12), + ; companion object { private val map = PersonRole.values().associateBy(PersonRole::role) fun fromInt(type: Int) = map[type] } } + @Serializable data class SeriesDto( val id: Int, @@ -47,7 +50,7 @@ data class SeriesDto( val format: Int, val created: String? = "", val libraryId: Int, - val libraryName: String? = "" + val libraryName: String? = "", ) @Serializable @@ -58,16 +61,18 @@ data class SeriesMetadataDto( val coverArtists: List = emptyList(), val genres: List = emptyList(), val seriesId: Int, - val ageRating: Int + val ageRating: Int, ) + @Serializable data class Genres( - val title: String + val title: String, ) + @Serializable data class Person( - val name: String + val name: String, ) @Serializable @@ -80,7 +85,7 @@ data class VolumeDto( val lastModified: String, val created: String, val seriesId: Int, - val chapters: List = emptyList() + val chapters: List = emptyList(), ) @Serializable @@ -94,5 +99,5 @@ data class ChapterDto( val pagesRead: Int, val coverImageLocked: Boolean, val volumeId: Int, - val created: String + val created: String, ) diff --git a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/MetadataDto.kt b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/MetadataDto.kt index b4939f238..73d492835 100644 --- a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/MetadataDto.kt +++ b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/MetadataDto.kt @@ -9,38 +9,45 @@ data class MetadataGenres( val id: Int, val title: String, ) + @Serializable data class MetadataPeople( val id: Int, val name: String, - val role: Int + val role: Int, ) + @Serializable data class MetadataPubStatus( val value: Int, - val title: String + val title: String, ) + @Serializable data class MetadataTag( val id: Int, val title: String, ) + @Serializable data class MetadataAgeRatings( val value: Int, - val title: String + val title: String, ) + @Serializable data class MetadataLanguages( val isoCode: String, - val title: String + val title: String, ) + @Serializable data class MetadataLibrary( val id: Int, val name: String, - val type: Int + val type: Int, ) + @Serializable data class MetadataCollections( val id: Int, @@ -51,7 +58,7 @@ data class MetadataPayload( val forceUseMetadataPayload: Boolean = true, var sorting: Int = 1, var sorting_asc: Boolean = true, - var readStatus: ArrayList = arrayListOf< String>(), + var readStatus: ArrayList = arrayListOf(), val readStatusList: List = listOf("notRead", "inProgress", "read"), var genres: ArrayList = arrayListOf(), var tags: ArrayList = arrayListOf(), diff --git a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/Responses.kt b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/Responses.kt index 8958eb769..424cc1233 100644 --- a/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/Responses.kt +++ b/src/all/kavita/src/eu/kanade/tachiyomi/extension/all/kavita/dto/Responses.kt @@ -6,7 +6,7 @@ import kotlinx.serialization.Serializable data class AuthenticationDto( val username: String, val token: String, - val apiKey: String + val apiKey: String, ) @Serializable @@ -14,8 +14,9 @@ data class PaginationInfo( val currentPage: Int, val itemsPerPage: Int, val totalItems: Int, - val totalPages: Int + val totalPages: Int, ) + @Serializable data class ServerInfoDto( val installId: String, @@ -23,5 +24,5 @@ data class ServerInfoDto( val isDocker: Boolean, val dotnetVersion: String, val kavitaVersion: String, - val numOfCores: Int + val numOfCores: Int, ) diff --git a/src/all/komga/src/eu/kanade/tachiyomi/extension/all/komga/Komga.kt b/src/all/komga/src/eu/kanade/tachiyomi/extension/all/komga/Komga.kt index 51f0a5b42..d40eacd93 100644 --- a/src/all/komga/src/eu/kanade/tachiyomi/extension/all/komga/Komga.kt +++ b/src/all/komga/src/eu/kanade/tachiyomi/extension/all/komga/Komga.kt @@ -245,7 +245,7 @@ open class Komga(private val suffix: String = "") : ConfigurableSource, Unmetere } Page( index = it.number - 1, - imageUrl = url + imageUrl = url, ) } } @@ -300,9 +300,9 @@ open class Komga(private val suffix: String = "") : ConfigurableSource, Unmetere private fun Response.fromReadList() = request.url.toString().contains("/api/v1/readlists") private fun parseDate(date: String?): Long = - if (date == null) + if (date == null) { 0 - else { + } else { try { KomgaHelper.formatterDate.parse(date)?.time ?: 0 } catch (ex: Exception) { @@ -311,9 +311,9 @@ open class Komga(private val suffix: String = "") : ConfigurableSource, Unmetere } private fun parseDateTime(date: String?): Long = - if (date == null) + if (date == null) { 0 - else { + } else { try { KomgaHelper.formatterDateTime.parse(date)?.time ?: 0 } catch (ex: Exception) { @@ -348,7 +348,7 @@ open class Komga(private val suffix: String = "") : ConfigurableSource, Unmetere private data class CollectionFilterEntry( val name: String, - val id: String? = null + val id: String? = null, ) { override fun toString() = name } @@ -365,7 +365,7 @@ open class Komga(private val suffix: String = "") : ConfigurableSource, Unmetere StatusGroup(listOf("Ongoing", "Ended", "Abandoned", "Hiatus").map { StatusFilter(it) }), GenreGroup(genres.map { GenreFilter(it) }), TagGroup(tags.map { TagFilter(it) }), - PublisherGroup(publishers.map { PublisherFilter(it) }) + PublisherGroup(publishers.map { PublisherFilter(it) }), ).also { list -> list.addAll(authors.map { (role, authors) -> AuthorGroup(role, authors.map { AuthorFilter(it) }) }) list.add(SeriesSort()) @@ -430,7 +430,7 @@ open class Komga(private val suffix: String = "") : ConfigurableSource, Unmetere title = "Source display name", default = suffix, summary = displayName.ifBlank { "Here you can change the source displayed suffix" }, - key = PREF_DISPLAYNAME + key = PREF_DISPLAYNAME, ) screen.addEditTextPreference( title = "Address", @@ -439,20 +439,20 @@ open class Komga(private val suffix: String = "") : ConfigurableSource, Unmetere inputType = InputType.TYPE_CLASS_TEXT or InputType.TYPE_TEXT_VARIATION_URI, validate = { it.toHttpUrlOrNull() != null }, validationMessage = "The URL is invalid or malformed", - key = PREF_ADDRESS + key = PREF_ADDRESS, ) screen.addEditTextPreference( title = "Username", default = USERNAME_DEFAULT, summary = username.ifBlank { "The user account email" }, - key = PREF_USERNAME + key = PREF_USERNAME, ) screen.addEditTextPreference( title = "Password", default = PASSWORD_DEFAULT, summary = if (password.isBlank()) "The user account password" else "*".repeat(password.length), inputType = InputType.TYPE_CLASS_TEXT or InputType.TYPE_TEXT_VARIATION_PASSWORD, - key = PREF_PASSWORD + key = PREF_PASSWORD, ) } @@ -478,23 +478,25 @@ open class Komga(private val suffix: String = "") : ConfigurableSource, Unmetere } if (validate != null) { - editText.addTextChangedListener(object : TextWatcher { - override fun beforeTextChanged(s: CharSequence?, start: Int, count: Int, after: Int) {} + editText.addTextChangedListener( + object : TextWatcher { + override fun beforeTextChanged(s: CharSequence?, start: Int, count: Int, after: Int) {} - override fun onTextChanged(s: CharSequence?, start: Int, before: Int, count: Int) {} + override fun onTextChanged(s: CharSequence?, start: Int, before: Int, count: Int) {} - override fun afterTextChanged(editable: Editable?) { - requireNotNull(editable) + override fun afterTextChanged(editable: Editable?) { + requireNotNull(editable) - val text = editable.toString() + val text = editable.toString() - val isValid = text.isBlank() || validate(text) + val isValid = text.isBlank() || validate(text) - editText.error = if (!isValid) validationMessage else null - editText.rootView.findViewById