summaryrefslogtreecommitdiffstats
path: root/lib/db.php
diff options
context:
space:
mode:
authorRobin Appelman <icewind1991@gmail.com>2011-10-17 00:24:42 +0200
committerRobin Appelman <icewind1991@gmail.com>2011-10-17 00:25:13 +0200
commit77378fa1893267bbdd6ee2f7805a34c1d5b0977b (patch)
treeae49da2a79b81df6f187e1c16d4bbb0683923756 /lib/db.php
parent330c513015f835bc0f7f4cc19e3c49fd9053e735 (diff)
downloadnextcloud-server-77378fa1893267bbdd6ee2f7805a34c1d5b0977b.tar.gz
nextcloud-server-77378fa1893267bbdd6ee2f7805a34c1d5b0977b.zip
fix now() function for sqlite3
Diffstat (limited to 'lib/db.php')
-rw-r--r--lib/db.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/db.php b/lib/db.php
index 78a4da10ce8..bcfda4592f2 100644
--- a/lib/db.php
+++ b/lib/db.php
@@ -350,7 +350,7 @@ class OC_DB {
$prefix = OC_Config::getValue( "dbtableprefix", "oc_" );
// differences in escaping of table names ('`' for mysql) and getting the current timestamp
- if( $type == 'sqlite' ){
+ if( $type == 'sqlite' || $type == 'sqlite3' ){
$query = str_replace( '`', '\'', $query );
$query = str_replace( 'NOW()', 'datetime(\'now\')', $query );
$query = str_replace( 'now()', 'datetime(\'now\')', $query );