Commit Graph

158 Commits (89fe9cbc204bc85d62055d4a28241a6d28808efa)

Author SHA1 Message Date
Aevann1 b6a5d010ca add "show more..." button 2022-06-29 02:55:44 +02:00
Aevann1 4580cf534d fix strikethrough regex 2022-06-28 08:05:49 +02:00
Aevann1 50121f6960 fixed strikethrough 2022-06-28 07:41:21 +02:00
Aevann1 e527dec36b fix mentions in marquees 2022-06-27 07:14:45 +02:00
Snakes aaf718c78c Fix timeout in sanitize from link_fix_regex.
h/t to @official-techsupport for finding and help fixing this bug.
When given certain pathological input, `sanitize` would time out
(notably only on posts, rather than comments, perhaps due to the
longer maximum length of input). For example, using as input the
result of:

    with open("test.txt", "w") as f:
        for i in range(26):
            f.write(f":{chr(ord('a') + i)}: ")
        f.write('x' * 20_000)

We believe this to be because of some combination of the greedy
quantifiers and the negative lookahead before the match. The regex
was rewritten to (in theory) have much more linear performance.
2022-06-25 01:28:43 -04:00
Aevann1 c5c21da76f validate colors 2022-06-24 19:32:31 +02:00
Aevann1 fcf600cb35 fix this https://chapotraphouse.club/post/79771/workaholics-are-worse-for-society-than/2183396?context=8#context 2022-06-24 16:45:19 +02:00
Aevann1 9593dc58dd move regex from helpers.const into its own helper file 2022-06-24 16:30:59 +02:00