Proyectos de Subversion Moodle

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 1441
Línea 50... Línea 50...
50
    public function __invoke()
50
    public function __invoke()
51
    {
51
    {
52
        $client = $this->client;
52
        $client = $this->client;
53
        return $client->assumeRoleAsync($this->assumeRoleParams)
53
        return $client->assumeRoleAsync($this->assumeRoleParams)
54
            ->then(function (Result $result) {
54
            ->then(function (Result $result) {
55
                return $this->client->createCredentials($result);
55
                return $this->client->createCredentials(
-
 
56
                    $result,
-
 
57
                    CredentialSources::STS_ASSUME_ROLE
-
 
58
                );
56
            })->otherwise(function (\RuntimeException $exception) {
59
            })->otherwise(function (\RuntimeException $exception) {
57
                throw new CredentialsException(
60
                throw new CredentialsException(
58
                    "Error in retrieving assume role credentials.",
61
                    "Error in retrieving assume role credentials.",
59
                    0,
62
                    0,
60
                    $exception
63
                    $exception