#1146 refactor function that load composer autoload