Aaah, you got me in the right direction. The problem was that json_decode in php didn't encode "true" and "false" to true and false. Hence
had been true even if the value was "false"
So everything cool now, thanks!