Skip to content
Snippets Groups Projects
Unverified Commit e9c00d3d authored by Christoph Wurst's avatar Christoph Wurst Committed by GitHub
Browse files

Merge pull request #3750 from nextcloud/techdept/psalm-nullable-return

Fix nullable return types reported by Psalm
parents 52680559 16709931
No related branches found
No related tags found
No related merge requests found
......@@ -89,7 +89,7 @@ class Container {
}
public function getParent(): Container {
if ($this->isRoot()) {
if ($this->isRoot() || $this->parent === null) {
throw new RuntimeException('Container root has no parent');
}
return $this->parent;
......
......@@ -203,9 +203,10 @@ class IspDbConfigurationDetector {
* @param MailAccount $account
* @param string $email
* @param string $password
* @return boolean
*
* @return bool|null
*/
private function testSmtpConfiguration(array $smtp, MailAccount $account, string $email, string $password) {
private function testSmtpConfiguration(array $smtp, MailAccount $account, string $email, string $password): ?bool {
try {
if ($smtp['username'] === '%EMAILADDRESS%') {
$user = $email;
......
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