This duplicates code you have in the switch() above, doesn't it?