replace with static function