Remove dependency on img