Skip to content

Commit fcea8fa

Browse files
committed
fixed messages
1 parent edbc3b5 commit fcea8fa

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

apps/app/src/pages/Home/popups/CodePopup/CodePopup.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const CodePopup: React.FC<CodePopupProps> = ({
2525
function handleCodeSubmit(code: string) {
2626
if (!geolocation.isOk) {
2727
setErrorMessage(
28-
`Ne možete unijeti kod izvan dozvoljene lokacije. ${geolocation?.error ?? ''}`,
28+
`${geolocation?.error ?? 'Ne možete unijeti kod izvan dozvoljene lokacije.'}`,
2929
);
3030
return;
3131
}

apps/app/src/pages/RateCompanyPage/RateCompanyPage.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,7 @@ export const RateCompanyPage = () => {
5454
}
5555

5656
if (!geolocation.isOk) {
57-
toast.error(
58-
`Ne možete ocijeniti štand izvan dozvoljene lokacije. ${geolocation?.error ?? ''}`,
59-
);
57+
toast.error(geolocation?.error ?? 'Ne možete ocijeniti štand izvan dozvoljene lokacije.');
6058
navigate(RouteNames.HOME);
6159
return;
6260
}

apps/app/src/pages/ScannerPage/ScannerPage.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,10 @@ const ScannerPage = () => {
4141
return;
4242
}
4343

44-
if (geolocation.isOk === false) {
44+
if (!geolocation.isOk) {
4545
toast.error(
46-
`Ne možete skenirati QR kod izvan dozvoljene lokacije. ${geolocation?.error ?? ''}`,
46+
geolocation?.error ??
47+
'Ne možete skenirati QR kod izvan dozvoljene lokacije.',
4748
);
4849
return;
4950
}

0 commit comments

Comments
 (0)