-
[wegram] Unhandled promise rejection .... currentUser.uidApp - Android 학습 일지 2022. 7. 23. 15:51
터미널상 에러
[Unhandled promise rejection: TypeError: null is not an object (evaluating 'currentUser.uid')] at node_modules/react-native/Libraries/Pressability/Pressability.js:702:17 in _performTransitionSideEffects at node_modules/react-native/Libraries/Pressability/Pressability.js:639:6 in _receiveSignal at node_modules/react-native/Libraries/Pressability/Pressability.js:520:8 in responderEventHandlers.onResponderRelease at node_modules/react-native/Libraries/Text/Text.js:112:14 in onResponderRelease
디바이스 상 에러
없는 값을 조회하려고 할때 발생하는 에러.....
Sol)
더보기[Unhandled promise rejection: TypeError: null is not an object (evaluating 'currentUser.email')]
currentUser에 값이 비어 있단 뜻입니다.
이 오류는
엑스포를 재실행 하거나, 서버가 리로드 될 때 (Xcode 저장 버튼 누르면, 보통 자동 리로드)
로그인이 풀려서 발생하는 오류입니다
이걸 해결하려면,....
로그인이 일단 되면, currentUser 값을 Asyncstorage에 담는 것이 방법이 될수 있습니다.
Asyncstorage는 서버가 리로드 되도, 값을 영구히 저장 하고 있기 때문입니다
앱을 처음 열어서 로그인이 안되어 있어서....
로그인 된석으로 표시된 점은 수정/보완할것...
'App - Android 학습 일지' 카테고리의 다른 글
AsyncStorage <import> (0) 2022.07.23 무한 스크롤 임계치는 기종마다 신경을 써줘야.. (0) 2022.07.23 Firebase SDK 업버전에 의한 호환성 처리 (0) 2022.07.02 외부 (무거운) 데이터 로딩시 (0) 2022.06.27 [W2-7] 페이지 로딩시 반복 방지 (0) 2022.06.27