I'm working on a simple RESTful API and have a basic model. The model has a field which is being cast to bool through a getter.
On output of controller if I do return json_encode(["asdf"=>$alert->is_seen]); I see asdf:false, however if I do: $this->response->setJsonContent($alert); I get is_seen: 0. Why is there this inconsistency?