Fix bug where the category was validated before it was submitted