[Ricardo Rodriguez] Your EPEC Network ICT Team wrote:
Guillaume Lerouge wrote:
The point seems to be how $bbdoc is assigned within the control
structure #foreach. Does this make sense for you? Thanks!
I must admit I have no idea why the code behaves this way, but since
your code apparently works better than mine I updated the XAR using it
:-) -> if it works let's use it ;-)
Thanks! After all this is about
collaboration!
The point is that $bbdoc gets the value of the first granted document,
let's say com.xpn.xwiki.api.Document@ab18cf, and this is the value used
for the no-granted entries from this point onwards. It will be great to
know why does this happen. Let's hope others have sometime to jump in
here and solve the doubt.
Cheers,
Ricardo
Simple. $xwiki.getDocument returns null if you can't access that
document. #set($var = null) will leave $var to its previous value
(velocity feature, can be configured to allow setting null, but it is
not allowed by default).
--
Sergiu Dumitriu
http://purl.org/net/sergiu/