$this->serialize isn't a function