Example #1
0
        .then((res) => {
          this.setState({
            passwordError: false
          });
          if (res.status === 500) {
            this.setState({
              error: 'User does not exists',
              isLoading: false
            });
          } else {

            this.setState({
              isLoading: false,
              error: false,
              username: '',
              password: '',
              newPassword: '',
              confirmNewPassword: ''
            });
            console.log('Password Changed');
            Keychain
              .resetGenericPassword()
              .then(function() {
                console.log('Credentials successfully deleted');
              });
            this.props.navigator.pop();
          }
        }).catch((err) => {
Example #2
0
 clearNativeCache = () => {
     resetGenericPassword();
     AsyncStorage.multiRemove([
         TOOLBAR_BACKGROUND,
         TOOLBAR_TEXT_COLOR,
         APP_BACKGROUND,
     ]);
 };
Example #3
0
 .then((res) => {
   this.setState({
     isLoading: false,
     error: false
   });
   console.log('Username Changed');
   this.props.route.username = this.state.username;
   Keychain
     .resetGenericPassword()
     .then(function() {
       console.log('Credentials successfully deleted');
     });
   this.props.navigator.popToTop();
 }).catch((err) => {
// $FlowExpectedError - First two arguments are required
setGenericPassword();
setGenericPassword('username', 'password').then(result => {
  (result: boolean);
});
setGenericPassword('username', 'password', 'service');
setGenericPassword('username', 'password', simpleOptions);

getGenericPassword().then(result => {
  (result: boolean | SharedWebCredentials);
});
getGenericPassword('service');
getGenericPassword(simpleOptions);

resetGenericPassword().then(result => {
  (result: boolean);
});
resetGenericPassword('service');
resetGenericPassword(simpleOptions);

requestSharedWebCredentials().then(result => {
  (result.server: string);
  (result.username: string);
  (result.password: string);
});

setSharedWebCredentials('server', 'username', 'password').then(result => {
  (result: void);
});