Skip to content
Snippets Groups Projects
Commit 7731c790 authored by Tim van Dijen's avatar Tim van Dijen
Browse files

Fix Psalm

parent 5ef4753f
Branches
Tags
No related merge requests found
......@@ -153,7 +153,10 @@ class SAMLBuilder
$metadata = Configuration::loadFromArray($metadata, $metadata['entityid']);
$defaultEndpoint = $metadata->getDefaultEndpoint('SingleSignOnService');
/** @psalm-var \SAML2\XML\md\RoleDescriptor $e */
/**
* @psalm-var \SAML2\XML\md\RoleDescriptor $e
* @psalm-suppress UndefinedClass
*/
$e = new SecurityTokenServiceType();
$e->setLocation($defaultEndpoint['Location']);
......
......@@ -265,7 +265,6 @@ class Session implements \Serializable, Utils\ClearableState
// check if we have stored a session stored with the session handler
try {
/** @var \SimpleSAML\Session|null $session Help Scrutinizer with the correct type */
$session = self::getSession();
} catch (\Exception $e) {
/*
......
......@@ -254,14 +254,7 @@ class EMail
$config = Configuration::getInstance();
$t = new Template($config, $template);
$twig = $t->getTwig();
if (!isset($twig)) {
throw new \Exception(
'Even though we explicitly configure that we want Twig,'
. ' the Template class does not give us Twig. This is a bug.'
);
}
$result = $twig->render($template, [
$result = $t->getTwig()->render($template, [
'subject' => $this->mail->Subject,
'text' => $this->text,
'data' => $this->data
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment