supabase / postgrest-dart

Dart client for PostgREST
https://supabase.com
MIT License
136 stars 38 forks source link

fix: calling multiple times will override the previous select #95

Closed dshukertjr closed 1 year ago

dshukertjr commented 1 year ago

What kind of change does this PR introduce?

Currently, calling .select() on query builder will add select=* every single time it's being called resulting in a url like this:

supabase.from('').select().select().select();

results in:

/rest/v1/todos?select=%2A&select=%2A&select=%2A

This PR fixes this so that calling multiple .select() will just override each other resulting in a URL like this:

/rest/v1/todos?select=%2A