From bd3f2ade87d63b5340bf3be26f33c6f74ac35f8c Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Mon, 18 Jan 2010 13:55:28 +0300 Subject: editTagsSave: invalidate article cache --- modules/backend-rpc.php | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'modules') diff --git a/modules/backend-rpc.php b/modules/backend-rpc.php index adefbd5a5..f994c3e8f 100644 --- a/modules/backend-rpc.php +++ b/modules/backend-rpc.php @@ -440,6 +440,8 @@ if ($subop == "setArticleTags") { + global $memcache; + $id = db_escape_string($_REQUEST["id"]); $tags_str = db_escape_string($_REQUEST["tags_str"]); @@ -480,6 +482,11 @@ db_query($link, "COMMIT"); + if ($memcache) { + $obj_id = md5("TAGS:".$_SESSION["uid"].":$id"); + $memcache->delete($obj_id); + } + $tags_str = format_tags_string(get_article_tags($link, $id), $id); print " -- cgit v1.2.3