fixed small bug which cut away the last digit of the price

This commit is contained in:
Julian Daube 2017-03-20 11:54:08 +01:00
parent d3cd46f5c8
commit d3f96c348a
1 changed files with 1 additions and 1 deletions

View File

@ -104,7 +104,7 @@ func (c *Connection) GetPrice(p Part) float32 {
// need to convert german decimals (using ,) to american decimals
// using .
str := strings.Replace(price[:i-1], ",", ".", 1)
str := strings.Replace(price[:i], ",", ".", 1)
ret, _ := strconv.ParseFloat(str, 32)
return float32(ret)
}