Skip to content

Commit cbe82c4

Browse files
committed
fix caching allowing non admins to read admin renderings
1 parent d9094de commit cbe82c4

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Zero-K.info/AppCode/ForumPostCache.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ void ZkDataContextOnAfterEntityChange(object sender, ZkDataContext.EntityEntry d
3939
}
4040

4141
private static string GetKey(ForumPost p) {
42-
return "p" + p.ForumPostID;
42+
return "p" + p.ForumPostID + "#" + Global.IsModerator;
4343
}
4444

4545
private static string GetKey(News n) {
46-
return "n" + n.NewsID;
46+
return "n" + n.NewsID + "#" + Global.IsModerator;
4747
}
4848

4949
public MvcHtmlString GetCachedHtml(ForumPost post, HtmlHelper html) {

0 commit comments

Comments
 (0)