fixed a bug in the category create implementation