summaryrefslogtreecommitdiff
path: root/conv
diff options
context:
space:
mode:
authorDave Henderson <dhenderson@gmail.com>2020-09-29 20:07:46 -0400
committerDave Henderson <dhenderson@gmail.com>2020-09-29 20:07:46 -0400
commit7c93217f5c6b2eb8830ddc1d6ed395f567832af6 (patch)
tree387df1e05f9fc189fc4bd9ec0bf6f39765845190 /conv
parentc75fa4aaaad4a9679b09cbfcb35c527d9a471d3b (diff)
Lint fixes
Signed-off-by: Dave Henderson <dhenderson@gmail.com>
Diffstat (limited to 'conv')
-rw-r--r--conv/conv.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/conv/conv.go b/conv/conv.go
index 52a0fb57..4fa5db74 100644
--- a/conv/conv.go
+++ b/conv/conv.go
@@ -260,7 +260,7 @@ func ToFloat64(v interface{}) float64 {
func strToInt64(str string) int64 {
if strings.Contains(str, ",") {
- str = strings.Replace(str, ",", "", -1)
+ str = strings.ReplaceAll(str, ",", "")
}
iv, err := strconv.ParseInt(str, 0, 64)
if err != nil {
@@ -277,7 +277,7 @@ func strToInt64(str string) int64 {
func strToFloat64(str string) float64 {
if strings.Contains(str, ",") {
- str = strings.Replace(str, ",", "", -1)
+ str = strings.ReplaceAll(str, ",", "")
}
// this is inefficient, but it's the only way I can think of to
// properly convert octal integers to floats