commit d963a25c5dc9a9e5695acb9eb129fad5a3adc07c
Author: Michal Schwob <michal.schwob@seznam.cz>
Date:   Tue Oct 17 09:52:47 2023 +0200

    REVERT: reverting debug toasts
    re #10822

diff --git a/src/api/authservice.ts b/src/api/authservice.ts
index 22dabf5..c8b053b 100644
--- a/src/api/authservice.ts
+++ b/src/api/authservice.ts
@@ -12,10 +12,6 @@ export const loginRequest = async (username: string, password: string) => {
 }
 
 export const isAuthRequest = async () => {
-    Toast.show({
-        title: `Checking auth ${axiosInstance.defaults.baseURL}`,
-        duration: 10000
-    })
     return await axiosInstance.get(
         "/isauth"
     )
diff --git a/src/pages/LoginPage.tsx b/src/pages/LoginPage.tsx
index dc3d0e2..eefc36f 100644
--- a/src/pages/LoginPage.tsx
+++ b/src/pages/LoginPage.tsx
@@ -1,25 +1,21 @@
 import {
     Center,
-    Box,
     Heading,
     VStack,
     FormControl,
-    Link,
     Input,
     Button,
-    HStack,
     Text,
-    KeyboardAvoidingView, useToast, ScrollView
+    KeyboardAvoidingView,
+    useToast
 } from "native-base"
-import { useCallback, useEffect, useState } from "react"
+import { useEffect, useState } from "react"
 import { useDispatch, useSelector } from "react-redux"
 import { checkAuth, login } from "../stores/actions/userThunks"
 import { AppDispatch, RootState } from "../stores/store"
 import { Platform } from "react-native"
 import { log } from "../logging/logger"
-import * as SplashScreen from "expo-splash-screen"
 import { ApplicationHeading } from "../components/reusables/ApplicationHeading"
-import {consumeError} from "../stores/reducers/userSlice"
 
 
 const LoginPage = () => {
@@ -48,7 +44,6 @@ const LoginPage = () => {
                 placement: "top",
                 duration: 3000,
             })
-            // dispatch(consumeError())
         }
     }, [lastError]);
 
@@ -58,7 +53,6 @@ const LoginPage = () => {
             flex={ 1 }
             justifyContent={ "center" }
             h={ {lg: "auto"} }
-            // behavior={ "padding" }
             keyboardVerticalOffset={ 100 }
         >
 
@@ -88,15 +82,13 @@ const LoginPage = () => {
                         Please log in to continue
                     </Text>
                     { lastError && (
-                        <ScrollView>
-                            <Text
-                                mt="1"
-                                textAlign="center"
-                                color="error.500"
-                            >
-                                { lastError }
-                            </Text>
-                        </ScrollView>
+                        <Text
+                            mt="1"
+                            textAlign="center"
+                            color="error.500"
+                        >
+                            { lastError }
+                        </Text>
                     ) }
 
                     <VStack space={ 3 } >
diff --git a/src/stores/actions/userThunks.ts b/src/stores/actions/userThunks.ts
index 5f99157..c21b560 100644
--- a/src/stores/actions/userThunks.ts
+++ b/src/stores/actions/userThunks.ts
@@ -1,7 +1,6 @@
 import { createAsyncThunk } from "@reduxjs/toolkit"
 import { isAuthRequest, loginRequest, logoutRequest } from "../../api/authservice"
 import { log } from "../../logging/logger"
-import {Toast} from "native-base"
 
 export const login = createAsyncThunk(
     "user/login",
@@ -16,18 +15,10 @@ export const login = createAsyncThunk(
                     role: response.data.role
                 }
             } else {
-                Toast.show({
-                    title: `Login not 200 (${response.status}): ${response}`,
-                    duration: 10000
-                })
                 return Promise.reject(response.data ? response.data : "Login failed")
             }
         } catch (err: any) {
-            Toast.show({
-                title: `Login err: ${err}`,
-                duration: 10000
-            })
-            return Promise.reject(err.response ? err.response.data : "Something went wrong" + err)
+            return Promise.reject(err.response ? err.response.data : "Something went wrong: " + err)
         }
     }
 )
@@ -39,31 +30,14 @@ export const checkAuth = createAsyncThunk(
             const response = await isAuthRequest()
             console.log(response)
             if (response.status === 200) {
-                Toast.show({
-                    title: `Auth ok: ${response.data}`,
-                    duration: 10000
-                })
                 return {
                     isLogged: response.data.isauth
                 }
             } else {
-                Toast.show({
-                    title: `Auth err: ${response.data ? response.data : "Check authentication failed"}`,
-                    duration: 10000
-                })
                 return Promise.reject(response.data ? response.data : "Check authentication failed")
             }
         } catch (err: any) {
-            Toast.show({
-                title: `Auth config: ${err.config}`,
-                duration: 10000
-            })
-
-            Toast.show({
-                title: `Auth message: ${err.message}`,
-                duration: 10000
-            })
-            return Promise.reject(`response: ${JSON.stringify(err.response?.data)}, request: ${JSON.stringify(err.request)}, config: ${JSON.stringify(err.config)}` )
+            return Promise.reject(err.response ? err.response.data : "Something went wrong: " + err)
         }
     }
 )
