Fix ArrayOutOfBoundException when switching panels with an empty Discrete measurement list