mirror of
https://github.com/typecho/typecho.git
synced 2025-01-29 02:08:12 +01:00
pgsql can also use unix_socket
fix Deprecated: pg_escape_string(): Automatic fetching of PostgreSQL connection
This commit is contained in:
parent
20537a0124
commit
45e244ede7
@ -119,7 +119,7 @@ class Pgsql implements Adapter
|
||||
|
||||
/**
|
||||
* @param resource $resource
|
||||
* @return array|null
|
||||
* @return array
|
||||
*/
|
||||
public function fetchAll($resource): array
|
||||
{
|
||||
@ -146,6 +146,6 @@ class Pgsql implements Adapter
|
||||
*/
|
||||
public function quoteValue($string): string
|
||||
{
|
||||
return '\'' . pg_escape_string($string) . '\'';
|
||||
return '\'' . str_replace("'", '"', $string) . '\'';
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user