Explorar el Código

Simplify parameter removal.

tags/v0.3.2
Ben Kurtovic hace 10 años
padre
commit
40b92358b4
Se han modificado 1 ficheros con 2 adiciones y 2 borrados
  1. +2
    -2
      mwparserfromhell/nodes/template.py

+ 2
- 2
mwparserfromhell/nodes/template.py Ver fichero

@@ -331,5 +331,5 @@ class Template(Node):
removed = True
if not removed:
raise ValueError(name)
for i, index in enumerate(to_remove):
self.params.pop(index - i) # Note the shift when we remove a param
for i in reversed(to_remove):
self.params.pop(i)

Cargando…
Cancelar
Guardar