Skip to content

Commit

Permalink
rename variable
Browse files Browse the repository at this point in the history
  • Loading branch information
zhyt1985 committed Apr 8, 2021
1 parent d300d30 commit 0306e87
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions geocsv/geocsv.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func (gc *GeoCSV) readRecords() (err error) {
err = readErr
return
}
encodeRecord := make([]string, 0, len(record))
encodeValues := make([]string, 0, len(record))
for _, value := range record {
var encodeValue string
coding := utils.GetStringEncoding(value)
Expand All @@ -82,13 +82,13 @@ func (gc *GeoCSV) readRecords() (err error) {
// remove special characters, such as 
encodeValue = strings.ReplaceAll(encodeValue, "\uFEFF", "")
encodeValue = strings.TrimSpace(encodeValue)
encodeRecord = append(encodeRecord, encodeValue)
encodeValues = append(encodeValues, encodeValue)
}
if !headerRead {
headerRead = true
gc.headers = encodeRecord
gc.headers = encodeValues
} else {
gc.rows = append(gc.rows, encodeRecord)
gc.rows = append(gc.rows, encodeValues)
}
}
return
Expand Down

0 comments on commit 0306e87

Please sign in to comment.