spl0k / supysonic

Supysonic is a Python implementation of the Subsonic server API.
https://supysonic.readthedocs.io
GNU Affero General Public License v3.0
264 stars 58 forks source link

getAlbumList.view returns one album for every song on it #199

Closed ogarcia closed 3 years ago

ogarcia commented 3 years ago

Sample request: curl 'https://supysonic.example.com/rest/getAlbumList.view?type=alphabeticalByName&size=20&offset=0&u=user&c=Ultrasonic&f=json&v=1.9.0&p=enc:LOVEISLOVE'

Current response:

{
  "subsonic-response": {
    "albumList": {
      "album": [
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "#3",
          "artist": "The Script",
          "coverArt": "455",
          "created": "2017-07-01T13:47:54",
          "id": "455",
          "isDir": true,
          "parent": "414",
          "title": "#3"
        },
        {
          "album": "(The Best of) New Order",
          "artist": "New Order",
          "coverArt": "833",
          "created": "2017-07-01T13:55:14",
          "id": "833",
          "isDir": true,
          "parent": "255",
          "title": "(The Best of) New Order"
        },
        {
          "album": "(The Best of) New Order",
          "artist": "New Order",
          "coverArt": "833",
          "created": "2017-07-01T13:55:14",
          "id": "833",
          "isDir": true,
          "parent": "255",
          "title": "(The Best of) New Order"
        },
        {
          "album": "(The Best of) New Order",
          "artist": "New Order",
          "coverArt": "833",
          "created": "2017-07-01T13:55:14",
          "id": "833",
          "isDir": true,
          "parent": "255",
          "title": "(The Best of) New Order"
        }
      ]
    },
    "status": "ok",
    "version": "1.9.0"
  }
}

Seems that add an album for every song that album contains