mirror of
https://codeberg.org/lucida/lucida.git
synced 2026-11-19 18:17:22 -05:00
make getTypeFromUrl async
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import crypto from 'crypto'
|
||||
import fetch from 'node-fetch'
|
||||
import {
|
||||
ItemType,
|
||||
StreamerWithLogin,
|
||||
SearchResults,
|
||||
GetByUrlResponse,
|
||||
@@ -214,7 +215,7 @@ export default class Qobuz implements StreamerWithLogin {
|
||||
}
|
||||
return [urlParts[0], urlParts[1]]
|
||||
}
|
||||
getTypeFromUrl(url: string): 'artist' | 'album' | 'track' {
|
||||
async getTypeFromUrl(url: string): Promise<ItemType> {
|
||||
return this.#getUrlParts(url)[0]
|
||||
}
|
||||
async getByUrl(url: string): Promise<GetByUrlResponse> {
|
||||
|
||||
Reference in New Issue
Block a user