mirror of https://github.com/kcal-app/kcal.git
Calculate Recipe ingredient nutrients from serving amount
This commit is contained in:
parent
aa84819df5
commit
c909d3b535
|
@ -146,7 +146,7 @@ final class IngredientAmount extends Model
|
|||
$this->amount,
|
||||
$this->unit
|
||||
),
|
||||
Recipe::class => $this->ingredient->{"{$method}Total"}(),
|
||||
Recipe::class => $this->ingredient->{"{$method}PerServing"}() * $this->amount,
|
||||
default => 0
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue