superUserNames() public method

Super users are users to whom the frozen status does not apply Typically, this has been used for automation & admins
public superUserNames ( ) : string[]
return string[] List of super users
Beispiel #1
0
 /**
  * @return boolean If the user doing the push is a super user
  */
 private function isSuperUser()
 {
     $optVarName = $this->config->envVarNameForPushUser();
     return $optVarName->map(function ($varName) {
         $superUsers = $this->config->superUserNames();
         $this->logger->trace(count($superUsers) . " superuser(s) configured");
         $currentUser = getenv($varName);
         $this->logger->trace("Current {$varName} is {$currentUser}");
         return in_array($currentUser, $superUsers);
     })->getOrElse(false);
 }