fixes #4 and fixes #5. Corrected input verification and popover error messages.