That would be ok except that it doesn't catch the case where the xml data
exists but either the version or createDate fields are missing.

I don't have an example of that case in the wild but covered it for the
sake of completeness.

We could also avoid the use of jobject by making the local $xmldata an
array and modifying the way we access it.
On May 12, 2014 2:44 PM, "Nikolai Plath" <notifications@github.com> wrote:

> In administrator/templates/hathor/html/com_templates/templates/default.php:
>
> > @@ -80,6 +80,21 @@
> >  		<tbody>
> >  		<?php foreach ($this->items as $i => $item) : ?>
> >  			<tr class="row<?php echo $i % 2; ?>">
> > +		            <?php
> > +		                    if (!$item->xmldata){
> > +		                        $xmldata = new JObject;
>
> JObject is somewhat deprecated, although there is no @deprecated tag..
>
> What if you just do a
>
> if (!$item->xmldata){
>    $item->xmldata = new JRegistry;}
>
> That would just display empty fields, without warnings ;)
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/joomla/joomla-cms/pull/3589/files#r12546406>
> .
>