Fixed problem with injection of dependency