summaryrefslogtreecommitdiff
path: root/app/Models/EntryDAOSQLite.php
diff options
context:
space:
mode:
authorGravatar Marien Fressinaud <dev@marienfressinaud.fr> 2014-10-31 17:21:20 +0100
committerGravatar Marien Fressinaud <dev@marienfressinaud.fr> 2014-10-31 17:21:20 +0100
commit105729639bd06c27536bbdd2968873046278d59f (patch)
tree30dcf7e3ae471b30810fb22ed701e0bb7d034fc8 /app/Models/EntryDAOSQLite.php
parentcaf98a6468dcea5ae8c38062e4eb527cb3667db9 (diff)
parentee50df518310d3aee5efb5a0c15548b457d10e7e (diff)
Merge branch 'beta' into hotfixes
Diffstat (limited to 'app/Models/EntryDAOSQLite.php')
-rw-r--r--app/Models/EntryDAOSQLite.php16
1 files changed, 8 insertions, 8 deletions
diff --git a/app/Models/EntryDAOSQLite.php b/app/Models/EntryDAOSQLite.php
index 9dc395c3c..4a3fe24a2 100644
--- a/app/Models/EntryDAOSQLite.php
+++ b/app/Models/EntryDAOSQLite.php
@@ -26,7 +26,7 @@ class FreshRSS_EntryDAOSQLite extends FreshRSS_EntryDAO {
return true;
} else {
$info = $stm == null ? array(2 => 'syntax error') : $stm->errorInfo();
- Minz_Log::record('SQL error updateCacheUnreads: ' . $info[2], Minz_Log::ERROR);
+ Minz_Log::error('SQL error updateCacheUnreads: ' . $info[2]);
return false;
}
}
@@ -47,7 +47,7 @@ class FreshRSS_EntryDAOSQLite extends FreshRSS_EntryDAO {
$stm = $this->bd->prepare($sql);
if (!($stm && $stm->execute($values))) {
$info = $stm == null ? array(2 => 'syntax error') : $stm->errorInfo();
- Minz_Log::record('SQL error markRead 1: ' . $info[2], Minz_Log::ERROR);
+ Minz_Log::error('SQL error markRead 1: ' . $info[2]);
$this->bd->rollBack();
return false;
}
@@ -59,7 +59,7 @@ class FreshRSS_EntryDAOSQLite extends FreshRSS_EntryDAO {
$stm = $this->bd->prepare($sql);
if (!($stm && $stm->execute($values))) {
$info = $stm == null ? array(2 => 'syntax error') : $stm->errorInfo();
- Minz_Log::record('SQL error markRead 2: ' . $info[2], Minz_Log::ERROR);
+ Minz_Log::error('SQL error markRead 2: ' . $info[2]);
$this->bd->rollBack();
return false;
}
@@ -72,7 +72,7 @@ class FreshRSS_EntryDAOSQLite extends FreshRSS_EntryDAO {
public function markReadEntries($idMax = 0, $onlyFavorites = false, $priorityMin = 0) {
if ($idMax == 0) {
$idMax = time() . '000000';
- Minz_Log::record('Calling markReadEntries(0) is deprecated!', Minz_Log::DEBUG);
+ Minz_Log::debug('Calling markReadEntries(0) is deprecated!');
}
$sql = 'UPDATE `' . $this->prefix . 'entry` SET is_read=1 WHERE is_read=0 AND id <= ?';
@@ -85,7 +85,7 @@ class FreshRSS_EntryDAOSQLite extends FreshRSS_EntryDAO {
$stm = $this->bd->prepare($sql);
if (!($stm && $stm->execute($values))) {
$info = $stm == null ? array(2 => 'syntax error') : $stm->errorInfo();
- Minz_Log::record('SQL error markReadEntries: ' . $info[2], Minz_Log::ERROR);
+ Minz_Log::error('SQL error markReadEntries: ' . $info[2]);
return false;
}
$affected = $stm->rowCount();
@@ -98,7 +98,7 @@ class FreshRSS_EntryDAOSQLite extends FreshRSS_EntryDAO {
public function markReadCat($id, $idMax = 0) {
if ($idMax == 0) {
$idMax = time() . '000000';
- Minz_Log::record('Calling markReadCat(0) is deprecated!', Minz_Log::DEBUG);
+ Minz_Log::debug('Calling markReadCat(0) is deprecated!');
}
$sql = 'UPDATE `' . $this->prefix . 'entry` '
@@ -109,7 +109,7 @@ class FreshRSS_EntryDAOSQLite extends FreshRSS_EntryDAO {
$stm = $this->bd->prepare($sql);
if (!($stm && $stm->execute($values))) {
$info = $stm == null ? array(2 => 'syntax error') : $stm->errorInfo();
- Minz_Log::record('SQL error markReadCat: ' . $info[2], Minz_Log::ERROR);
+ Minz_Log::error('SQL error markReadCat: ' . $info[2]);
return false;
}
$affected = $stm->rowCount();
@@ -124,6 +124,6 @@ class FreshRSS_EntryDAOSQLite extends FreshRSS_EntryDAO {
}
public function size($all = false) {
- return @filesize(DATA_PATH . '/' . Minz_Session::param('currentUser', '_') . '.sqlite');
+ return @filesize(DATA_PATH . '/' . $this->current_user . '.sqlite');
}
}