X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/8eda8735d7a36f3752f1d426cad1fb0002b30cca..e470a947218ecf042ca75c69d4579a052199e570:/lib/controller/rpc/conn.go diff --git a/lib/controller/rpc/conn.go b/lib/controller/rpc/conn.go index bf6166f44f..4b143b770b 100644 --- a/lib/controller/rpc/conn.go +++ b/lib/controller/rpc/conn.go @@ -145,6 +145,14 @@ func (conn *Conn) Login(ctx context.Context, options arvados.LoginOptions) (arva return resp, err } +func (conn *Conn) Logout(ctx context.Context, options arvados.LogoutOptions) (arvados.LogoutResponse, error) { + ep := arvados.EndpointLogout + var resp arvados.LogoutResponse + err := conn.requestAndDecode(ctx, &resp, ep, nil, options) + resp.RedirectLocation = conn.relativeToBaseURL(resp.RedirectLocation) + return resp, err +} + // If the given location is a valid URL and its origin is the same as // conn.baseURL, return it as a relative URL. Otherwise, return it // unmodified.