That looks like the correct fix.  I would prefer that you copy the function from
one of the other modules - getContext(data) - to WebMacroSitePage and then use
it; as opposed to putting the code inline.  Then submit a patch, please.

Thank you,
John McNally

[EMAIL PROTECTED] wrote:
> 
> Hi
> 
> This is in contnuation to my earlier mail.
> 
> I have modified the "doBuildBeforeAction( data )" in
> WebMacroSitePage class as follows :
> 
> protected void doBuildBeforeAction(RunData data) throws Exception
> {
>         // this is original
>         /*
>         WebContext wc_data = TurbineWebMacro.getContext(data);
>         data.getTemplateInfo().setTemplateContext
>                      (WebMacroService.WEBMACRO_CONTEXT, wc_data);
>         */
> 
>         // this is by venkat
>         // Attempt to get it from the session first.  If it
>         // doesn't exist, create it and then stuff it into the
>         // session.
>         WebContext wc_data = (WebContext) data.getTemplateInfo
>         ().getTemplateContext(WebMacroService.WEBMACRO_CONTEXT);
>         if (wc_data == null)
>         {
>             wc_data = TurbineWebMacro.getContext(data);
>         }
>         data.getTemplateInfo().setTemplateContext
>            (WebMacroService.WEBMACRO_CONTEXT, wc_data);
> }
> 
>


------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to