Fix "index out of bounds" error on component select screen