From 655e98d776301958d4e34b7159a27a84470a86bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jaime=20Pe=CC=81rez=20Crespo?= <jaime.perez@uninett.no> Date: Wed, 17 Oct 2018 15:14:24 +0200 Subject: [PATCH] Add a method to get the (normalized) template name from a XHTML\Template object. This is useful when testing. --- lib/SimpleSAML/XHTML/Template.php | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lib/SimpleSAML/XHTML/Template.php b/lib/SimpleSAML/XHTML/Template.php index cbac41a20..ef9e0e6b7 100644 --- a/lib/SimpleSAML/XHTML/Template.php +++ b/lib/SimpleSAML/XHTML/Template.php @@ -142,6 +142,17 @@ class Template extends Response } + /** + * Get the normalized template name. + * + * @return string The name of the template to use. + */ + public function getTemplateName() + { + return $this->normalizeTemplateName($this->template); + } + + /** * Normalize the name of the template to one of the possible alternatives. * -- GitLab