Hello,
No, file that you tried to edit is not correct, so change it back. If you need to fix the Products element then take et-core-plugin/app/traits/elementor.php file from fixed site to any other site you need and after that resave the Elementor element settings.
Regardd