public function instead of event