Fix category assignment