Fix Errors

syntax fix

raise general error if status type isn't known