mirror of
https://github.com/ecency/ecency-mobile.git
synced 2024-11-23 08:27:30 +03:00
Fixed private key login set pin issue
This commit is contained in:
parent
3a66df95b9
commit
4d263db416
@ -3,6 +3,7 @@ import { Alert, Linking, Platform } from 'react-native';
|
||||
import { connect } from 'react-redux';
|
||||
import { injectIntl } from 'react-intl';
|
||||
import AppCenter from 'appcenter';
|
||||
import Config from 'react-native-config';
|
||||
|
||||
// Services and Actions
|
||||
import { login } from '../../../providers/steem/auth';
|
||||
@ -13,9 +14,14 @@ import {
|
||||
addOtherAccount,
|
||||
updateCurrentAccount,
|
||||
} from '../../../redux/actions/accountAction';
|
||||
import { login as loginAction, openPinCodeModal } from '../../../redux/actions/applicationActions';
|
||||
import {
|
||||
login as loginAction,
|
||||
openPinCodeModal,
|
||||
setPinCode,
|
||||
} from '../../../redux/actions/applicationActions';
|
||||
import { setPushTokenSaved } from '../../../realm/realm';
|
||||
import { setPushToken } from '../../../providers/esteem/esteem';
|
||||
import { encryptKey } from '../../../utils/crypto';
|
||||
|
||||
// Middleware
|
||||
|
||||
@ -62,6 +68,8 @@ class LoginContainer extends PureComponent {
|
||||
if (isPinCodeOpen) {
|
||||
dispatch(openPinCodeModal({ navigateTo: ROUTES.DRAWER.MAIN }));
|
||||
} else {
|
||||
const encryptedPin = encryptKey(Config.DEFAULT_PIN, Config.PIN_KEY);
|
||||
dispatch(setPinCode(encryptedPin));
|
||||
navigation.navigate({
|
||||
routeName: ROUTES.DRAWER.MAIN,
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user