shrink array if selection was applied