DeviantArt: Fix NullPointerException for some galleries (#6812)
Select always-present element for gallery name
This commit is contained in:
parent
c3c87863b2
commit
065ff132a0
|
@ -1,7 +1,7 @@
|
|||
ext {
|
||||
extName = 'DeviantArt'
|
||||
extClass = '.DeviantArt'
|
||||
extVersionCode = 1
|
||||
extVersionCode = 2
|
||||
isNsfw = true
|
||||
}
|
||||
|
||||
|
|
|
@ -74,7 +74,7 @@ class DeviantArt : HttpSource() {
|
|||
val manga = SManga.create().apply {
|
||||
// If manga is sub-gallery then use sub-gallery name, else use gallery name
|
||||
title = subFolderGallery?.selectFirst("._2vMZg + ._2vMZg")?.text()?.substringBeforeLast(" ")
|
||||
?: document.selectFirst(".ds-card-selected h2")!!.text()
|
||||
?: subFolderGallery?.selectFirst("[aria-haspopup=listbox] > div")!!.ownText()
|
||||
author = document.title().substringBefore(" ")
|
||||
description = subFolderGallery?.selectFirst(".legacy-journal")?.wholeText()
|
||||
thumbnail_url = subFolderGallery?.selectFirst("img[property=contentUrl]")?.absUrl("src")
|
||||
|
|
Loading…
Reference in New Issue