|
@@ -129,7 +129,7 @@ discard block |
|
|
block discarded – undo |
|
129
|
129
|
* @return \core\AbstractProfile[] list of Profiles of this IdP |
|
130
|
130
|
*/ |
|
131
|
131
|
public function listProfiles(bool $activeOnly = FALSE) { |
|
132
|
|
- $query = "SELECT profile_id FROM profile WHERE inst_id = $this->identifier" . ($activeOnly ? " AND showtime = 1" : ""); |
|
|
132
|
+ $query = "SELECT profile_id FROM profile WHERE inst_id = $this->identifier".($activeOnly ? " AND showtime = 1" : ""); |
|
133
|
133
|
$allProfiles = $this->databaseHandle->exec($query); |
|
134
|
134
|
$returnarray = []; |
|
135
|
135
|
// SELECT -> resource, not boolean |
|
@@ -139,7 +139,7 @@ discard block |
|
|
block discarded – undo |
|
139
|
139
|
$returnarray[] = $oneProfile; |
|
140
|
140
|
} |
|
141
|
141
|
|
|
142
|
|
- $this->loggerInstance->debug(4, "listProfiles: " . print_r($returnarray, true)); |
|
|
142
|
+ $this->loggerInstance->debug(4, "listProfiles: ".print_r($returnarray, true)); |
|
143
|
143
|
return $returnarray; |
|
144
|
144
|
} |
|
145
|
145
|
|
|
@@ -150,7 +150,7 @@ discard block |
|
|
block discarded – undo |
|
150
|
150
|
* @return \core\AbstractDeployment[] list of deployments of this IdP |
|
151
|
151
|
*/ |
|
152
|
152
|
public function listDeployments(bool $activeOnly = FALSE) { |
|
153
|
|
- $query = "SELECT deployment_id FROM deployment WHERE inst_id = $this->identifier" . ($activeOnly ? " AND status = " . AbstractDeployment::ACTIVE : ""); |
|
|
153
|
+ $query = "SELECT deployment_id FROM deployment WHERE inst_id = $this->identifier".($activeOnly ? " AND status = ".AbstractDeployment::ACTIVE : ""); |
|
154
|
154
|
$allDeployments = $this->databaseHandle->exec($query); |
|
155
|
155
|
$returnarray = []; |
|
156
|
156
|
// SELECT -> resource, not boolean |
|
@@ -158,7 +158,7 @@ discard block |
|
|
block discarded – undo |
|
158
|
158
|
$returnarray[] = new DeploymentManaged($this, $deploymentQuery->deployment_id); |
|
159
|
159
|
} |
|
160
|
160
|
|
|
161
|
|
- $this->loggerInstance->debug(4, "listDeployments: " . print_r($returnarray, true)); |
|
|
161
|
+ $this->loggerInstance->debug(4, "listDeployments: ".print_r($returnarray, true)); |
|
162
|
162
|
return $returnarray; |
|
163
|
163
|
} |
|
164
|
164
|
|
|
@@ -291,7 +291,7 @@ discard block |
|
|
block discarded – undo |
|
291
|
291
|
case AbstractProfile::PROFILETYPE_SILVERBULLET: |
|
292
|
292
|
$theProfile = new ProfileSilverbullet($identifier, $this); |
|
293
|
293
|
$theProfile->addSupportedEapMethod(new \core\common\EAP(\core\common\EAP::EAPTYPE_SILVERBULLET), 1); |
|
294
|
|
- $theProfile->setRealm($this->identifier . "-" . $theProfile->identifier . "." . strtolower($this->federation) . strtolower(CONFIG_CONFASSISTANT['SILVERBULLET']['realm_suffix'])); |
|
|
294
|
+ $theProfile->setRealm($this->identifier."-".$theProfile->identifier.".".strtolower($this->federation).strtolower(CONFIG_CONFASSISTANT['SILVERBULLET']['realm_suffix'])); |
|
295
|
295
|
return $theProfile; |
|
296
|
296
|
default: |
|
297
|
297
|
throw new Exception("This type of profile is unknown and can not be added."); |
|
@@ -428,7 +428,7 @@ discard block |
|
|
block discarded – undo |
|
428
|
428
|
*/ |
|
429
|
429
|
public function getExternalDBId() { |
|
430
|
430
|
if (CONFIG_CONFASSISTANT['CONSORTIUM']['name'] == "eduroam" && isset(CONFIG_CONFASSISTANT['CONSORTIUM']['deployment-voodoo']) && CONFIG_CONFASSISTANT['CONSORTIUM']['deployment-voodoo'] == "Operations Team") { // SW: APPROVED |
|
431
|
|
- $idQuery = $this->databaseHandle->exec("SELECT external_db_id FROM institution WHERE inst_id = $this->identifier AND external_db_syncstate = " . self::EXTERNAL_DB_SYNCSTATE_SYNCED); |
|
|
431
|
+ $idQuery = $this->databaseHandle->exec("SELECT external_db_id FROM institution WHERE inst_id = $this->identifier AND external_db_syncstate = ".self::EXTERNAL_DB_SYNCSTATE_SYNCED); |
|
432
|
432
|
// SELECT -> it's a resource, not a boolean |
|
433
|
433
|
if (mysqli_num_rows(/** @scrutinizer ignore-type */ $idQuery) == 0) { |
|
434
|
434
|
return FALSE; |