Refactor imgs