added missing check; switch cases do not see capible of accessing array contents at a case index..?