mirror of
https://github.com/Shabinder/SpotiFlyer.git
synced 2024-11-25 10:24:31 +01:00
Saavn Link Extraction Fix
This commit is contained in:
parent
994b20d0a1
commit
37fe18ef16
@ -88,7 +88,7 @@ actual fun GithubLogo() = rememberVectorPainter(vectorXmlResource("drawable/ic_g
|
||||
actual fun PaypalLogo() = rememberVectorPainter(vectorXmlResource("drawable/ic_paypal_logo.xml")) as Painter
|
||||
|
||||
@Composable
|
||||
actual fun OpenCollectiveLogo() = rememberVectorPainter(vectorXmlResource("drawable/ic_opencollective_icon")) as Painter
|
||||
actual fun OpenCollectiveLogo() = rememberVectorPainter(vectorXmlResource("drawable/ic_opencollective_icon.xml")) as Painter
|
||||
|
||||
@Composable
|
||||
actual fun RazorPay() = rememberVectorPainter(vectorXmlResource("drawable/ic_indian_rupee.xml")) as Painter
|
||||
|
@ -31,8 +31,9 @@ class SaavnProvider(
|
||||
trackList = listOf(),
|
||||
Source.JioSaavn
|
||||
).apply {
|
||||
when (fullLink.substringAfter("saavn.com/").substringBefore("/")) {
|
||||
"song" -> {
|
||||
val pageLink = fullLink.substringAfter("saavn.com/").substringBefore("?")
|
||||
when {
|
||||
pageLink.contains("/song/",true) -> {
|
||||
getSong(fullLink).value.let {
|
||||
folderType = "Tracks"
|
||||
subFolder = ""
|
||||
@ -41,7 +42,7 @@ class SaavnProvider(
|
||||
coverUrl = it.image.replace("http:", "https:")
|
||||
}
|
||||
}
|
||||
"album" -> {
|
||||
pageLink.contains("/album/",true) -> {
|
||||
getAlbum(fullLink).value.let {
|
||||
folderType = "Albums"
|
||||
subFolder = removeIllegalChars(it.title)
|
||||
@ -50,7 +51,7 @@ class SaavnProvider(
|
||||
coverUrl = it.image.replace("http:", "https:")
|
||||
}
|
||||
}
|
||||
"featured" -> { // Playlist
|
||||
pageLink.contains("/featured/",true) -> { // Playlist
|
||||
getPlaylist(fullLink).value.let {
|
||||
folderType = "Playlists"
|
||||
subFolder = removeIllegalChars(it.listname)
|
||||
|
Loading…
Reference in New Issue
Block a user