Fixed installing packages before retrieving them