/** * When an User updates his profile, we need to * make sure that every post written by him is also * updated with his name and username. * * @return void */ function after_update() { $post = new PostModel(); $post->updateAuthorInfo($this->getID()); }