esoftplay 0.0.110-d → 0.0.110-h
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/build.js +0 -1
- package/modules/lib/curl.ts +4 -1
- package/modules/user/index.tsx +9 -19
- package/package.json +1 -1
package/bin/build.js
CHANGED
package/modules/lib/curl.ts
CHANGED
|
@@ -391,7 +391,10 @@ export default class ecurl {
|
|
|
391
391
|
private refineErrorMessage(resText: string): string {
|
|
392
392
|
let out = resText
|
|
393
393
|
if (!esp.isDebug('')) {
|
|
394
|
-
if (
|
|
394
|
+
if (
|
|
395
|
+
resText.toLowerCase().includes('failed')
|
|
396
|
+
|| resText.toLowerCase().includes('code')
|
|
397
|
+
|| resText.toLowerCase().includes('timeout exceeded')) {
|
|
395
398
|
// reportApiError(this.fetchConf.options, resText)
|
|
396
399
|
out = 'Terjadi kesalahan, biar ' + esp.appjson()?.expo?.name + ' bereskan, silahkan coba beberapa saat lagi.'
|
|
397
400
|
}
|
package/modules/user/index.tsx
CHANGED
|
@@ -1,16 +1,12 @@
|
|
|
1
1
|
// withHooks
|
|
2
2
|
// noPage
|
|
3
3
|
|
|
4
|
-
import { esp, LibDialog, LibImage, LibNet_status, LibProgress, LibStyle, LibToast, LibUpdaterProperty, LibVersion, LibWorker, LibWorkloop, LibWorkview, UseDeeplink, UserClass, UserLoading, UserMain, UserRoutes, useSafeState, _global } from 'esoftplay';
|
|
5
|
-
import * as Font from "expo-font";
|
|
6
|
-
import firebase from 'firebase';
|
|
7
4
|
import React, { useEffect, useMemo } from "react";
|
|
8
5
|
import { Alert, View } from "react-native";
|
|
9
|
-
import { getReactNativePersistence } from 'firebase/auth/react-native';
|
|
10
|
-
import AsyncStorage from '@react-native-async-storage/async-storage';
|
|
11
|
-
|
|
12
|
-
//@ts-ignore
|
|
13
6
|
import Navs from "../../cache/navs";
|
|
7
|
+
import { esp, LibDialog, LibImage, LibNet_status, LibProgress, LibStyle, LibToast, LibUpdaterProperty, LibVersion, LibWorker, LibWorkloop, LibWorkview, UseDeeplink, UserClass, UserLoading, UserMain, UserRoutes, useSafeState, _global } from 'esoftplay';
|
|
8
|
+
import * as Font from "expo-font";
|
|
9
|
+
|
|
14
10
|
|
|
15
11
|
export interface UserIndexProps {
|
|
16
12
|
|
|
@@ -33,13 +29,6 @@ function setFonts(): Promise<void> {
|
|
|
33
29
|
})
|
|
34
30
|
}
|
|
35
31
|
|
|
36
|
-
/*
|
|
37
|
-
import { getReactNativePersistence } from 'firebase/auth/react-native';
|
|
38
|
-
import AsyncStorage from '@react-native-async-storage/async-storage';
|
|
39
|
-
|
|
40
|
-
const auth = initializeAuth(firebaseApp, );
|
|
41
|
-
*/
|
|
42
|
-
|
|
43
32
|
|
|
44
33
|
export default function m(props: UserIndexProps): any {
|
|
45
34
|
const [loading, setLoading] = useSafeState(true)
|
|
@@ -66,11 +55,12 @@ export default function m(props: UserIndexProps): any {
|
|
|
66
55
|
], { cancelable: false })
|
|
67
56
|
}, 30 * 1000);
|
|
68
57
|
if (esp.config('firebase').hasOwnProperty('apiKey')) {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
58
|
+
try {
|
|
59
|
+
const chatFirebase = require('../chatting/firebase')?.default
|
|
60
|
+
if (chatFirebase)
|
|
61
|
+
chatFirebase?.signInAnonymously?.();
|
|
62
|
+
} catch (error) {
|
|
63
|
+
|
|
74
64
|
}
|
|
75
65
|
}
|
|
76
66
|
UserClass.isLogin(async () => {
|