mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-02 16:15:59 +08:00
Fix lint errors in modified code in the /pkg directory (#1962)
* /pkg-make lint Signed-off-by: longyuqing112 <105913803+longyuqing112@users.noreply.github.com> * /pkg_make_lint Signed-off-by: longyuqing112 <105913803+longyuqing112@users.noreply.github.com> --------- Signed-off-by: longyuqing112 <105913803+longyuqing112@users.noreply.github.com>
This commit is contained in:
@@ -259,7 +259,7 @@ func (a *Aws) StatObject(ctx context.Context, name string) (*s3.ObjectInfo, erro
|
||||
return res, nil
|
||||
}
|
||||
|
||||
// AccessURL todo
|
||||
// AccessURL todo.
|
||||
func (a *Aws) AccessURL(ctx context.Context, name string, expire time.Duration, opt *s3.AccessURLOption) (string, error) {
|
||||
// todo
|
||||
return "", nil
|
||||
|
||||
@@ -64,7 +64,7 @@ func (u *UserMongoDriver) AddSubscriptionList(ctx context.Context, userID string
|
||||
}
|
||||
// iterate over aggregated results
|
||||
for cursor.Next(ctx) {
|
||||
err := cursor.Decode(&cnt)
|
||||
err = cursor.Decode(&cnt)
|
||||
if err != nil {
|
||||
return errs.Wrap(err)
|
||||
}
|
||||
|
||||
@@ -29,6 +29,8 @@ import (
|
||||
"github.com/OpenIMSDK/tools/mcontext"
|
||||
"google.golang.org/protobuf/proto"
|
||||
|
||||
"fmt"
|
||||
|
||||
"github.com/openimsdk/open-im-server/v3/pkg/common/config"
|
||||
)
|
||||
|
||||
@@ -118,7 +120,11 @@ func configureProducerAck(p *Producer, ackConfig string) {
|
||||
// configureCompression configures the message compression type for the producer.
|
||||
func configureCompression(p *Producer, compressType string) {
|
||||
var compress sarama.CompressionCodec = sarama.CompressionNone
|
||||
compress.UnmarshalText(bytes.ToLower([]byte(compressType)))
|
||||
err := compress.UnmarshalText(bytes.ToLower([]byte(compressType)))
|
||||
if err != nil {
|
||||
fmt.Printf("Failed to configure compression: %v\n", err)
|
||||
return
|
||||
}
|
||||
p.config.Producer.Compression = compress
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user