aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorlolcat <will@lolcat.ca>2025-09-06 09:44:05 -0400
committerlolcat <will@lolcat.ca>2025-09-06 09:44:05 -0400
commitc44d6292a02041dca8d0f572ee7d00e01254ab48 (patch)
tree7534b5072db90221f1610121ecad27585794a150 /lib
parent0b350d4d6efc5ee013137ab037cd13c28c19a60e (diff)
holy shit can i stop fucking up this function for fucks sake
Diffstat (limited to 'lib')
-rw-r--r--lib/fuckhtml.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/fuckhtml.php b/lib/fuckhtml.php
index c914bc6..b05c5b2 100644
--- a/lib/fuckhtml.php
+++ b/lib/fuckhtml.php
@@ -554,11 +554,14 @@ class fuckhtml{
case "\"":
case "'":
if(
- $i > 2 && // only check if a quote could be there
+ $i > 1 && // only check if a quote could be there
(
(
$json[$i - 1] === "\\" &&
- $json[$i - 2] === "\\"
+ (
+ $i === 2 ||
+ $json[$i - 2] === "\\"
+ )
) ||
$json[$i - 1] !== "\\"
)
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage