mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-11-05 11:52:10 +08:00
fix: pkg update.
This commit is contained in:
parent
7ddcd08685
commit
9146b947a2
@ -19,6 +19,7 @@ import (
|
|||||||
"context"
|
"context"
|
||||||
"errors"
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/openimsdk/open-im-server/v3/pkg/common/servererrs"
|
||||||
"image"
|
"image"
|
||||||
"image/gif"
|
"image/gif"
|
||||||
"image/jpeg"
|
"image/jpeg"
|
||||||
@ -31,7 +32,6 @@ import (
|
|||||||
"github.com/minio/minio-go/v7"
|
"github.com/minio/minio-go/v7"
|
||||||
"github.com/openimsdk/open-im-server/v3/pkg/common/db/cache"
|
"github.com/openimsdk/open-im-server/v3/pkg/common/db/cache"
|
||||||
"github.com/openimsdk/open-im-server/v3/pkg/common/db/s3"
|
"github.com/openimsdk/open-im-server/v3/pkg/common/db/s3"
|
||||||
"github.com/openimsdk/tools/errs"
|
|
||||||
"github.com/openimsdk/tools/log"
|
"github.com/openimsdk/tools/log"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -45,7 +45,7 @@ func (m *Minio) getImageThumbnailURL(ctx context.Context, name string, expire ti
|
|||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
if !info.IsImg {
|
if !info.IsImg {
|
||||||
return "", errs.ErrData.WrapMsg("object not image")
|
return "", servererrs.ErrData.WrapMsg("object not image")
|
||||||
}
|
}
|
||||||
if opt.Width > info.Width || opt.Width <= 0 {
|
if opt.Width > info.Width || opt.Width <= 0 {
|
||||||
opt.Width = info.Width
|
opt.Width = info.Width
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user