fixed bugs on category