fix few bugs having to do with electrodes staying in grid after having been moved to unsorted