mirror of
https://github.com/lumapu/ahoy.git
synced 2025-07-27 13:17:11 +02:00
fix logout
This commit is contained in:
parent
4c52e9c307
commit
43af07716e
3 changed files with 6 additions and 4 deletions
|
@ -26,7 +26,7 @@
|
||||||
//#define AP_ONLY
|
//#define AP_ONLY
|
||||||
|
|
||||||
// timeout for automatic logoff (20 minutes)
|
// timeout for automatic logoff (20 minutes)
|
||||||
#define LOGOUT_TIMEOUT (20 * 60 * 60)
|
#define LOGOUT_TIMEOUT (20 * 60)
|
||||||
|
|
||||||
//-------------------------------------
|
//-------------------------------------
|
||||||
// CONFIGURATION - COMPILE TIME
|
// CONFIGURATION - COMPILE TIME
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
//-------------------------------------
|
//-------------------------------------
|
||||||
#define VERSION_MAJOR 0
|
#define VERSION_MAJOR 0
|
||||||
#define VERSION_MINOR 5
|
#define VERSION_MINOR 5
|
||||||
#define VERSION_PATCH 40
|
#define VERSION_PATCH 42
|
||||||
|
|
||||||
//-------------------------------------
|
//-------------------------------------
|
||||||
typedef struct {
|
typedef struct {
|
||||||
|
|
|
@ -107,8 +107,10 @@ void web::loop(void) {
|
||||||
void web::tickSecond() {
|
void web::tickSecond() {
|
||||||
if(0 != mLogoutTimeout) {
|
if(0 != mLogoutTimeout) {
|
||||||
mLogoutTimeout -= 1;
|
mLogoutTimeout -= 1;
|
||||||
if(0 == mLogoutTimeout)
|
if(0 == mLogoutTimeout) {
|
||||||
|
if(strlen(mConfig->sys.adminPwd) > 0)
|
||||||
mProtected = true;
|
mProtected = true;
|
||||||
|
}
|
||||||
|
|
||||||
DPRINTLN(DBG_DEBUG, "auto logout in " + String(mLogoutTimeout));
|
DPRINTLN(DBG_DEBUG, "auto logout in " + String(mLogoutTimeout));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue