working on saving the category to database