maybe you can extract these 2 lines into some static function to be used in the converter & here