Skip to content

Commit

Permalink
Fix bugs as suggested by scrutinizer-ci.com .
Browse files Browse the repository at this point in the history
  • Loading branch information
terrencegf committed Nov 25, 2019
1 parent 4f0147e commit b2c8b64
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/Service/Content.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ public static function printHeader($title = '', $extra = '', $csrfcookie = true)
$skin = Util::getSkin();
$skinpoweredbyimg = (string)$skin->getConfigOption('poweredbyimg');
if (
(!is_null($skinpoweredbyimg)) &&
(strlen($skinpoweredbyimg) > 0) &&
(is_readable('/var/www/html' . $skinpoweredbyimg))
) {
Expand Down Expand Up @@ -244,7 +243,7 @@ public static function printWAYF($showremember = true, $samlidps = false)
// If no previous providerId, get from skin, or default to Google.
if (strlen($providerId) == 0) {
$initialidp = (string)$skin->getConfigOption('initialidp');
if ((!is_null($initialidp)) && (isset($idps[$initialidp]))) {
if ((strlen($initialidp) > 0) && (isset($idps[$initialidp]))) {
$providerId = $initialidp;
} else {
$providerId = Util::getAuthzUrl('Google');
Expand Down Expand Up @@ -2123,7 +2122,7 @@ public static function reformatDN($dn)
{
$newdn = $dn;
$dnformat = (string)Util::getSkin()->getConfigOption('dnformat');
if (!is_null($dnformat)) {
if (strlen($dnformat) > 0) {
if (
($dnformat == 'rfc2253') &&
(preg_match(
Expand Down

0 comments on commit b2c8b64

Please sign in to comment.