diff options
author | zotlabs <mike@macgirvin.com> | 2019-11-13 04:25:25 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2019-11-13 08:57:12 +0100 |
commit | 3a2fdec241b84bd4ae559565876c6869e1c067fe (patch) | |
tree | 0c9e3c2ea2a80974a451881521b0605b1794bf96 | |
parent | 08b804cd2d365a35f26cc7e6b8fb838a0679fa97 (diff) | |
download | volse-hubzilla-3a2fdec241b84bd4ae559565876c6869e1c067fe.tar.gz volse-hubzilla-3a2fdec241b84bd4ae559565876c6869e1c067fe.tar.bz2 volse-hubzilla-3a2fdec241b84bd4ae559565876c6869e1c067fe.zip |
wildcard tag issue
(cherry picked from commit 2f4c619d510e64eeda05366e485d50f490cefebe)
-rw-r--r-- | include/text.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/text.php b/include/text.php index daa3c4c94..44af40810 100644 --- a/include/text.php +++ b/include/text.php @@ -2789,6 +2789,9 @@ function handle_tag(&$body, &$str_tags, $profile_uid, $tag, $in_network = true) // select someone by attag or nick and the name passed in if(! $r) { + // strip user-supplied wildcards before running a wildcard search + $newname = str_replace('%','',$newname); + $r = q("SELECT * FROM abook left join xchan on abook_xchan = xchan_hash WHERE xchan_addr like ('%s') AND abook_channel = %d ", dbesc(((strpos($newname,'@')) ? $newname : $newname . '@%')), |