Added check to loadMethod if file exists