mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-09 13:50:18 -06:00
add ugly CI hack: os.Getenv("STORAGE_USERS_DRIVER") != "owncloud"
This commit is contained in:
@@ -6,6 +6,7 @@ import (
|
||||
"encoding/hex"
|
||||
"fmt"
|
||||
"net/http"
|
||||
"os"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
@@ -366,9 +367,7 @@ func (o Ocs) DeleteUser(w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
if o.config.RevaAddress != "" {
|
||||
// Note that the previous conditional is short circuiting this. This logic will NOT run when the user's backend is
|
||||
// configured to use any other than the accounts service.
|
||||
if o.config.RevaAddress != "" && os.Getenv("STORAGE_USERS_DRIVER") != "owncloud" {
|
||||
t, err := o.mintTokenForUser(r.Context(), account)
|
||||
if err != nil {
|
||||
render.Render(w, r, response.ErrRender(data.MetaServerError.StatusCode, errors.Wrap(err, "could not mint token").Error()))
|
||||
@@ -388,6 +387,14 @@ func (o Ocs) DeleteUser(w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
if homeResp.Status.Code != rpcv1beta1.Code_CODE_OK {
|
||||
o.logger.Error().
|
||||
Str("stat_status_code", homeResp.Status.Code.String()).
|
||||
Str("stat_message", homeResp.Status.Message).
|
||||
Msg("DeleteUser: could not get user home: get failed")
|
||||
return
|
||||
}
|
||||
|
||||
statResp, err := gwc.Stat(ctx, &provider.StatRequest{
|
||||
Ref: &provider.Reference{
|
||||
Spec: &provider.Reference_Path{
|
||||
|
||||
Reference in New Issue
Block a user