Procházet zdrojové kódy

Forgot the extras folder

tags/v0.1
Riamse před 11 roky
rodič
revize
aa4b45c1bb
2 změnil soubory, kde provedl 11 přidání a 5 odebrání
  1. +6
    -3
      mwparserfromhell/nodes/extras/attribute.py
  2. +5
    -2
      mwparserfromhell/nodes/extras/parameter.py

+ 6
- 3
mwparserfromhell/nodes/extras/attribute.py Zobrazit soubor

@@ -20,7 +20,10 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

from __future__ import unicode_literals

from ...string_mixin import StringMixIn
from ...compat import str, bytes

__all__ = ["Attribute"]

@@ -34,9 +37,9 @@ class Attribute(StringMixIn):
def __unicode__(self):
if self.value:
if self.quoted:
return unicode(self.name) + '="' + unicode(self.value) + '"'
return unicode(self.name) + "=" + unicode(self.value)
return unicode(self.name)
return str(self.name) + '="' + str(self.value) + '"'
return str(self.name) + "=" + str(self.value)
return str(self.name)

@property
def name(self):


+ 5
- 2
mwparserfromhell/nodes/extras/parameter.py Zobrazit soubor

@@ -20,8 +20,11 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

from __future__ import unicode_literals

from ...string_mixin import StringMixIn
from ...utils import parse_anything
from ...compat import str, bytes

__all__ = ["Parameter"]

@@ -34,8 +37,8 @@ class Parameter(StringMixIn):

def __unicode__(self):
if self.showkey:
return unicode(self.name) + "=" + unicode(self.value)
return unicode(self.value)
return str(self.name) + "=" + str(self.value)
return str(self.value)

@property
def name(self):


Načítá se…
Zrušit
Uložit