Smalyshev added a comment.
Wow this is messed up. You could use D modifier though: https://3v4l.org/33Gks http://php.net/manual/en/reference.pcre.pattern.modifiers.php D (PCRE_DOLLAR_ENDONLY) If this modifier is set, a dollar metacharacter in the pattern matches only at the end of the subject string. Without this modifier, a dollar also matches immediately before the final character if it is a newline (but not before any other newlines). This modifier is ignored if m modifier is set. There is no equivalent to this modifier in Perl. Existance of this modifier shows somebody already encountered this WTF :) TASK DETAIL https://phabricator.wikimedia.org/T110728 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: thiemowmde, Smalyshev Cc: thiemowmde, daniel, Aklapper, Smalyshev, Lewizho99, Maathavan, D3r1ck01, Izno, Wikidata-bugs, aude, Mbch331 _______________________________________________ Wikidata-bugs mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs
