mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-23 05:50:55 +01:00
Storage - fix more query errors by escaping collate_text and collate_sort
Summary: second bit of https://github.com/phacility/phabricator/pull/729 Test Plan: this is a weird pull request merge Reviewers: chad, epriestley Reviewed By: epriestley Subscribers: Korvin, epriestley Differential Revision: https://secure.phabricator.com/D10646
This commit is contained in:
parent
31817b9097
commit
0bbe3a6d28
1 changed files with 4 additions and 2 deletions
|
@ -192,8 +192,10 @@ final class PhabricatorStorageManagementAPI {
|
|||
foreach ($queries as $query) {
|
||||
$query = str_replace('{$NAMESPACE}', $this->namespace, $query);
|
||||
$query = str_replace('{$CHARSET}', $charset, $query);
|
||||
$query = str_replace('{$COLLATE_TEXT}', $collate_text, $query);
|
||||
$query = str_replace('{$COLLATE_SORT}', $collate_sort, $query);
|
||||
$escaped_text = qsprintf($conn, '%T', $collate_text);
|
||||
$query = str_replace('{$COLLATE_TEXT}', $escaped_text, $query);
|
||||
$escaped_text = qsprintf($conn, '%T', $collate_sort);
|
||||
$query = str_replace('{$COLLATE_SORT}', $escaped_text, $query);
|
||||
queryfx(
|
||||
$conn,
|
||||
'%Q',
|
||||
|
|
Loading…
Reference in a new issue