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

Remove occurences of assert() with string argument

parent f80686f8
No related branches found
No related tags found
No related merge requests found
......@@ -33,7 +33,7 @@ if (array_key_exists(\SimpleSAML\Auth\State::EXCEPTION_PARAM, $_REQUEST)) {
// This is just a simple example of an error
$state = \SimpleSAML\Auth\State::loadExceptionState();
assert('array_key_exists(\SimpleSAML\Auth\State::EXCEPTION_DATA, $state)');
assert(array_key_exists(\SimpleSAML\Auth\State::EXCEPTION_DATA, $state));
$e = $state[\SimpleSAML\Auth\State::EXCEPTION_DATA];
throw $e;
......
......@@ -403,7 +403,7 @@ class PowerIdPDisco extends \SimpleSAML\XHTML\IdPDisco
*/
protected function setPreviousIdP($idp)
{
assert('is_string($idp)');
assert(is_string($idp));
if ($this->cdcDomain === null) {
parent::setPreviousIdP($idp);
......
......@@ -50,7 +50,7 @@ function showEntry($t, $metadata, $favourite = FALSE) {
function getTranslatedName($t, $metadata) {
if (isset($metadata['UIInfo']['DisplayName'])) {
$displayName = $metadata['UIInfo']['DisplayName'];
assert('is_array($displayName)'); // Should always be an array of language code -> translation
assert(is_array($displayName)); // Should always be an array of language code -> translation
if (!empty($displayName)) {
return $t->getTranslator()->getPreferredTranslation($displayName);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment