Sfoglia il codice sorgente

More sophisticated regex for parsing links.

tags/v0.1^2
Ben Kurtovic 12 anni fa
parent
commit
7cda82546a
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. +1
    -1
      earwigbot/commands/dictionary.py

+ 1
- 1
earwigbot/commands/dictionary.py Vedi File

@@ -128,7 +128,7 @@ class Dictionary(Command):
def parse_body(self, body):
substitutions = [
("<!--(.*?)-->", ""),
("\[\[(.*?)\|(.*?)\]\]", r"\2"),
("\[\[[^\]|]*?\|([^\]|]*?)\]\]", r"\1"),
("\{\{(.*?) of\|(.*?)\}\}", r"\1 of \2."),
("\{\{w\|(.*?)\}\}", r"\1"),
("\{\{surname(.*?)\}\}", r"A surname."),


Caricamento…
Annulla
Salva