Remove redundant conversion in event_writer.go (#12590)

Signed-off-by: Congqi Xia <congqi.xia@zilliz.com>
This commit is contained in:
congqixia 2021-12-02 19:15:33 +08:00 committed by GitHub
parent 45cbec1f7b
commit 21a6ce8647
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,7 +17,6 @@ import (
"errors"
"fmt"
"io"
"strconv"
"github.com/milvus-io/milvus/internal/common"
"github.com/milvus-io/milvus/internal/proto/schemapb"
@ -86,7 +85,7 @@ func readMagicNumber(buffer io.Reader) (int32, error) {
return -1, err
}
if magicNumber != MagicNumber {
return -1, fmt.Errorf("parse magic number failed, expected: %s, actual: %s", strconv.Itoa(int(MagicNumber)), strconv.Itoa(int(magicNumber)))
return -1, fmt.Errorf("parse magic number failed, expected: %d, actual: %d", MagicNumber, magicNumber)
}
return magicNumber, nil