} //Determine if we should include autoLogout Code $ipLocation = $locationSingleton->getIPLocation(); $ipId = $locationSingleton->getIPid(); $interface->assign('automaticTimeoutLength', 0); $interface->assign('automaticTimeoutLengthLoggedOut', 0); if (!is_null($ipLocation) && $ipLocation != false) { $interface->assign('onInternalIP', true); if (isset($user->bypassAutoLogout) && $user->bypassAutoLogout == 1) { $interface->assign('includeAutoLogoutCode', false); } else { $includeAutoLogoutCode = true; //Get the PType for the user /** @var MillenniumDriver|CatalogConnection $catalog */ $catalog = new CatalogConnection($configArray['Catalog']['driver']); if ($user && $catalog->checkFunction('isUserStaff')) { $userIsStaff = $catalog->isUserStaff(); $interface->assign('userIsStaff', $userIsStaff); if ($userIsStaff) { //Check to see if the user has overridden the auto logout code. if ($user->bypassAutoLogout != 0) { $includeAutoLogoutCode = false; } } } //Only include auto logout code if we are not on the home page if ($module == 'Search' && $action == 'Home') { $includeAutoLogoutCode = false; } $interface->assign('includeAutoLogoutCode', $includeAutoLogoutCode); }