For performance reasons it can be beneficial to only process context_nodeapi() once per page load.

CommentFileSizeAuthor
#1 context-n610742.patch1.05 KBdamienmckenna

Comments

damienmckenna’s picture

StatusFileSize
new1.05 KB

Here's a starting point.

damienmckenna’s picture

Status: Active » Needs review
steven jones’s picture

Status: Needs review » Closed (won't fix)

Looking at the nodeapi implementation of context at the moment, it only does the heavy lifting when the $op == 'view' and $page == TRUE, which is only going to be called at most once per page anyway right?

I don't think we need the static variable here, it reduces readability for not much gain, unless you can convince me otherwise :-)