public static function isParticipantsLastPassActive($testRefId, $userId) { global $ilDB, $lng, $ilPluginAdmin; /* @var ilObjTest $testOBJ */ $testOBJ = ilObjectFactory::getInstanceByRefId($testRefId, false); $activeId = $testOBJ->getActiveIdOfUser($userId); require_once 'Modules/Test/classes/class.ilTestSessionFactory.php'; $testSessionFactory = new ilTestSessionFactory($testOBJ); // Added temporarily bugfix smeyer $testSessionFactory->reset(); require_once 'Modules/Test/classes/class.ilTestSequenceFactory.php'; $testSequenceFactory = new ilTestSequenceFactory($ilDB, $lng, $ilPluginAdmin, $testOBJ); $testSession = $testSessionFactory->getSession($activeId); $testSequence = $testSequenceFactory->getSequenceByActiveIdAndPass($activeId, $testSession->getPass()); $testSequence->loadFromDb(); return $testSequence->hasSequence(); }