mirror of
https://github.com/openziti/zrok.git
synced 2025-02-23 13:41:04 +01:00
update error messaging
This commit is contained in:
parent
b69780908c
commit
f7d4dfba1b
@ -137,11 +137,11 @@ func (h *shareHandler) Handle(params share.ShareParams, principal *rest_model_zr
|
|||||||
|
|
||||||
sh, err := str.FindShareWithToken(sshr.Token, trx)
|
sh, err := str.FindShareWithToken(sshr.Token, trx)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logrus.Errorf("error checking share token collision: %v", err)
|
logrus.Errorf("error checking share for token collision: %v", err)
|
||||||
return share.NewShareInternalServerError()
|
return share.NewShareInternalServerError()
|
||||||
}
|
}
|
||||||
if sh != nil {
|
if sh != nil {
|
||||||
logrus.Errorf("attempting to create share with conflcting token: %v", sshr.Token)
|
logrus.Errorf("token '%v' already exists; cannot create share", sshr.Token)
|
||||||
return share.NewShareConflict()
|
return share.NewShareConflict()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user