Fixed get_countries_charts

This commit is contained in:
RemixDev 2021-04-21 20:58:19 +02:00
parent 3c2918751e
commit 896722cea5
3 changed files with 5 additions and 5 deletions

View file

@ -417,8 +417,8 @@ class API{
// Extra calls
async get_countries_charts(){
let temp = await this.get_user_playlists('637006841', {index:0, limit:-1})['data']
let result = temp.sort((a, b) => a.title.localeCompare(b.title)) // Sort all playlists
let temp = await this.get_user_playlists('637006841', {index:0, limit:-1})
let result = temp['data'].sort((a, b) => a.title.localeCompare(b.title)) // Sort all playlists
if (!result[0].title.startsWith('Top')) result.shift() // Remove loved tracks playlist
return result
}

4
package-lock.json generated
View file

@ -1,11 +1,11 @@
{
"name": "deezer-js",
"version": "0.0.5",
"version": "0.0.6",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"version": "0.0.5",
"version": "0.0.6",
"license": "GPL-3.0-or-later",
"dependencies": {
"got": "^11.8.2",

View file

@ -1,6 +1,6 @@
{
"name": "deezer-js",
"version": "0.0.5",
"version": "0.0.6",
"description": "A wrapper for all Deezer's APIs",
"main": "deezer/index.js",
"scripts": {