Allow 1/16th to be a fraction (small salt amounts)

This commit is contained in:
Mikhail Epifanov
2022-10-03 12:37:09 +02:00
committed by GitHub
parent 00ed9b07b6
commit bee5d6b7eb

View File

@ -280,7 +280,7 @@ export function getUserPreference(pref = undefined) {
export function calculateAmount(amount, factor) {
if (getUserPreference("use_fractions")) {
let return_string = ""
let fraction = frac(amount * factor, 10, true)
let fraction = frac(amount * factor, 16, true)
if (fraction[0] === 0 && fraction[1] === 0 && fraction[2] === 1) {
return roundDecimals(amount * factor)