Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 1 addition & 8 deletions src/sources/spotify.ts
Original file line number Diff line number Diff line change
Expand Up @@ -777,14 +777,7 @@ export default class SpotifySource implements SourceInstance {
return this.getRecommendations(query)

try {
let limit = this.config.playlistLoadLimit || 10

// fixes the error Argument <limit> for field /searchV2 cannot be greater than 1000
// this is a config issue from the user side, but if this can be used as a workaround,
// we set it to 10 to avoid the error :p.
if (limit > 999) {
limit = 10
}
let limit = Math.min(Math.max(this.nodelink.options.search.maxResults ?? 10, 1), 50)

// Priority 1: Internal Search (Rich nodes + Local matching)
if (this.anonymousToken || this.config.sp_dc) {
Expand Down
Loading