Feathersjs find request "invalid query parameter" error with reactjs

943 Views Asked by At

When I add $show:true to the data (shown below), the find request shows an error.

When I remove $show:true, there is no error and working fine.

Error is

Invalid query parameter $show.

I tried using different $values but the server always shows 'invalid parameter $values'

data = {$noshow:true,$show:true} ; 
let res = await client.service('servv').find({query:data});
1

There are 1 best solutions below

3
Daff On

In Feathers, query parameters starting with a $ are treated as special parameters. Often they can be used to make database specific queries (instead of just querying properties) which is why they have to be explicitly allowed on the server in the service configuration (see https://docs.feathersjs.com/api/databases/common.html#options).