johannesschobel / dingoquerymapper

Uses Dingo/API Request Query Parameters to filter Laravel Models
MIT License
12 stars 6 forks source link

Fixing issues with collection data and query parameters containing single quotes #13

Closed sgtwinters closed 6 years ago

sgtwinters commented 6 years ago

This is a suggestion to fix #12.

While looking into this I also found out that passing single quotes text as query parameters is breaking things. Therefore I added escaping to the setQueryParameters method as well.

johannesschobel commented 6 years ago

Hey man.. thanks a lot for your PR.. wouldn't it be better to use the addslashes function here? Maybe a "double quote" will also break the function here? addslashes : http://php.net/manual/en/function.addslashes.php

sgtwinters commented 6 years ago

Without a doubt, new PR coming up ;)

johannesschobel commented 6 years ago

you could have updated this PR accordingly. No need to submit a new PR.. ;) Thank you very much - let's continue in the new PR..