Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6715fe78 authored by Arnau Vàzquez's avatar Arnau Vàzquez
Browse files

Add 2 second delay to replicate user creation before set

parent 25ad5ce3
Loading
Loading
Loading
Loading
+4 −3
Original line number Original line Diff line number Diff line
@@ -55,7 +55,7 @@ class BaseEcloudAccountCreator implements AccountCreator
            // Create HME Alias
            // Create HME Alias
            $hmeAlias = $this->createHMEAlias($email, $commonApiUrl, $commonApiVersion, $aliasDomain);
            $hmeAlias = $this->createHMEAlias($email, $commonApiUrl, $commonApiVersion, $aliasDomain);
            // Create Alias to new domain
            // Create Alias to new domain
            $this->createNewDomainAlias($username, $email, $commonApiUrl, $commonApiVersion, $aliasDomain);
            // $this->createNewDomainAlias($username, $email, $commonApiUrl, $commonApiVersion, $aliasDomain);


            // Create alias with same name as email pointing to email to block this alias
            // Create alias with same name as email pointing to email to block this alias
            $domain = getMailDomain();
            $domain = getMailDomain();
@@ -63,6 +63,7 @@ class BaseEcloudAccountCreator implements AccountCreator
        } catch (Error $e) {
        } catch (Error $e) {
            error_log('Error during alias creation for user: ' . $username . ' with email: ' . $email . ' : ' . $e->getMessage());
            error_log('Error during alias creation for user: ' . $username . ' with email: ' . $email . ' : ' . $e->getMessage());
        }
        }
        sleep(2);
        $answer = $this->setAccountDataAtNextcloud($username, $email, $quota, $authmail, $hmeAlias);
        $answer = $this->setAccountDataAtNextcloud($username, $email, $quota, $authmail, $hmeAlias);
        return $answer;
        return $answer;
    }
    }