getRemainingTime treats logout_regardless_of_activity as always active

Created on 5 August 2022, over 2 years ago
Updated 13 February 2024, 9 months ago

Problem/Motivation

AutologoutManager::getRemainingTime() has a bug where it treats the logout_regardless_of_activity config option as though it is true always. This leads to the wrong value for $time_passed being set.

Steps to reproduce

Enable the autologout module. Don't enable the logout_regardless_of_activity setting. Place a breakpoint in AutologoutManager::getRemainingTime() and watch it execute the incorrect if block.

Proposed resolution

Replace the incorrect line $this->configFactory->get('logout_regardless_of_activity') with $this->autoLogoutSettings->get('logout_regardless_of_activity').

🐛 Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024