Further adjusted the way that categories list is produced.