From 90558a3a28c00f1624e5ef7c1254abd85120d081 Mon Sep 17 00:00:00 2001 From: Emma Eilefsen Glenna Date: Thu, 25 Jan 2024 18:58:39 +0000 Subject: [PATCH] add comment --- frontend/src/features/register/useRegister.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/frontend/src/features/register/useRegister.ts b/frontend/src/features/register/useRegister.ts index 22f7778..b2c01c9 100644 --- a/frontend/src/features/register/useRegister.ts +++ b/frontend/src/features/register/useRegister.ts @@ -53,6 +53,8 @@ export const useRegister = () => { setOrder(newOrder); }; + // This value does not interact with the backend or any financial logic. + // It is only used for rendering the sum total in the browser. The actual total is handled entirely by the backend. const total = Number(sumTotal(products, order, selectedUser === USER_EXTERNAL).toFixed(2)); const onSubmit = async () => {