Because the ```search``` call clears KEY_SET, so it's an error if you don't set it again.