summaryrefslogtreecommitdiff
path: root/include/sessions.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2017-04-26 15:29:22 +0300
committerAndrew Dolgov <[email protected]>2017-04-26 15:29:22 +0300
commit7b55001eeeb326323d020dcfac2f864f8c3ad633 (patch)
tree92b09e0349b49b1741a8b45172974addb136fbc5 /include/sessions.php
parentb49bb441f4fc722911794e80366d37df626a5613 (diff)
fix various issues reported by static analysis
update gitlab-ci config
Diffstat (limited to 'include/sessions.php')
-rw-r--r--include/sessions.php11
1 files changed, 8 insertions, 3 deletions
diff --git a/include/sessions.php b/include/sessions.php
index 1ed9be550..e955c70b2 100644
--- a/include/sessions.php
+++ b/include/sessions.php
@@ -23,7 +23,7 @@
ini_set("session.gc_maxlifetime", $session_expire);
ini_set("session.cookie_lifetime", min(0, SESSION_COOKIE_LIFETIME));
- function session_get_schema_version($nocache = false) {
+ function session_get_schema_version() {
global $schema_version;
if (!$schema_version) {
@@ -39,7 +39,7 @@
function validate_session() {
if (SINGLE_USER_MODE) return true;
- if (isset($_SESSION["ref_schema_version"]) && $_SESSION["ref_schema_version"] != session_get_schema_version(true)) {
+ if (isset($_SESSION["ref_schema_version"]) && $_SESSION["ref_schema_version"] != session_get_schema_version()) {
$_SESSION["login_error_msg"] =
__("Session failed to validate (schema version changed)");
return false;
@@ -72,7 +72,9 @@
return true;
}
-
+ /**
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
+ */
function ttrss_open ($s, $n) {
return true;
}
@@ -117,6 +119,9 @@
return true;
}
+ /**
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
+ */
function ttrss_gc ($expire) {
Db::get()->query("DELETE FROM ttrss_sessions WHERE expire < " . time());