summaryrefslogtreecommitdiff
path: root/classes/prefs.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2022-06-10 13:39:00 +0300
committerAndrew Dolgov <[email protected]>2022-06-10 13:39:00 +0300
commitcf1eaeedf3026948cf2210af1c747bdc3522d6ff (patch)
tree31780f12fb075b6b37be7a8f2fb813ba9db4980a /classes/prefs.php
parent2975c7297b680e486f326939b9fba82d8cf18035 (diff)
* add UserHelper methods to manipulate user database (add, modify, delete)
* expose said methods via CLI (update.php) * fix several invocations of deprecated functions * set stricter type hints on several method arguments
Diffstat (limited to 'classes/prefs.php')
-rw-r--r--classes/prefs.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/classes/prefs.php b/classes/prefs.php
index 7e6033f4d..378fea293 100644
--- a/classes/prefs.php
+++ b/classes/prefs.php
@@ -230,7 +230,7 @@ class Prefs {
}
}
- if (get_schema_version() >= 141) {
+ if (Config::get_schema_version() >= 141) {
// fill in any overrides from the database
$sth = $this->pdo->prepare("SELECT pref_name, value FROM ttrss_user_prefs2
WHERE owner_uid = :uid AND
@@ -265,7 +265,7 @@ class Prefs {
if ($this->_is_cached($pref_name, $owner_uid, $profile_id)) {
$cached_value = $this->_get_cache($pref_name, $owner_uid, $profile_id);
return Config::cast_to($cached_value, $type_hint);
- } else if (get_schema_version() >= 141) {
+ } else if (Config::get_schema_version() >= 141) {
$sth = $this->pdo->prepare("SELECT value FROM ttrss_user_prefs2
WHERE pref_name = :name AND owner_uid = :uid AND
(profile = :profile OR (:profile IS NULL AND profile IS NULL))");
@@ -390,7 +390,7 @@ class Prefs {
}
function migrate(int $owner_uid, ?int $profile_id): void {
- if (get_schema_version() < 141)
+ if (Config::get_schema_version() < 141)
return;
if (!$profile_id) $profile_id = null;