I use searchkick for geoloc and it work fine, the problem is my query return me all users in the perimeter including the user who do the request.
So for the moment I have
res = User.search "*", where: {location: {near: [@user.current_position.latitude, @user.current_position.longitude], within: params[:perimeter] + "mi"}}
And I want something like that :
res = User.search "*", where: {location: {near: [@user.current_position.latitude, @user.current_position.longitude], within: params[:perimeter] + "mi"}, {:email != @user.email}}
to get only the users different than the user who do the query.
I'm not a ruby specialist so I don't find the correct syntax to do this. Any help ?