added resize to index