Hello, I added this because of a warning (error) with pychecker. On the contrary of the other blocks, the variable uri "wasn't" declared and initialized whereas it was used in this block. But perhaps I misunderstood, I don't know Python.
python -tt <filename> or pychecker <filename> didn't complain after this add. Are there other ways to check that everything is ok so I'll use them next time ? Julien. --- En date de : Lun 14.3.11, Caolán McNamara <caol...@redhat.com> a écrit : > De: Caolán McNamara <caol...@redhat.com> > Objet: Re: [Libreoffice] Rewiew needed for pythonscript.py patch (new try) > À: "Julien Nabet" <serval2...@yahoo.fr> > Cc: "Christian Lohmaier" <lohmaier+libreoff...@googlemail.com>, > libreoffice@lists.freedesktop.org > Date: Lundi 14 mars 2011, 13h36 > On Sat, 2011-03-12 at 23:43 +0100, > Julien Nabet wrote: > > And now, ladies and gentlemen, the patch ! :-) > > Why the addition of a "uri = expandUri( name )" into > replaceByName ?, > i.e. this hunk > > @@ -962,8 +964,9 @@ class PythonScriptProvider( > unohelper.Base, > XBrowseNode, XScriptProvider, XNameC > > def replaceByName( self, name, > value ): > ... > - removeByName( name ) > - insertByName( name ) > + uri = expandUri( name ) > + self.removeByName( name ) > + self.insertByName( name, value > ) > ... > > C. > > _______________________________________________ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice