mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-10-31 19:15:58 +01:00 
			
		
		
		
	fix: delete category cache key on category create
This commit is contained in:
		| @@ -83,7 +83,11 @@ module.exports = function (Categories) { | ||||
| 		await privileges.categories.give(modPrivileges, category.cid, ['administrators', 'Global Moderators']); | ||||
| 		await privileges.categories.give(['groups:find', 'groups:read', 'groups:topics:read'], category.cid, ['guests', 'spiders']); | ||||
|  | ||||
| 		cache.del(['categories:cid', `cid:${parentCid}:children`]); | ||||
| 		cache.del([ | ||||
| 			'categories:cid', | ||||
| 			`cid:${parentCid}:children`, | ||||
| 			`cid:${parentCid}:children:all`, | ||||
| 		]); | ||||
| 		if (data.cloneFromCid && parseInt(data.cloneFromCid, 10)) { | ||||
| 			category = await Categories.copySettingsFrom(data.cloneFromCid, category.cid, !data.parentCid); | ||||
| 		} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user