Error message only comes up if invalid option is checked