mg-library 1.0.386 → 1.0.388

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.
Files changed (3) hide show
  1. package/blocks.js +0 -1
  2. package/login.js +7 -3
  3. package/package.json +1 -1
package/blocks.js CHANGED
@@ -114,7 +114,6 @@ export function MGLogin(props) {
114
114
  mgLoginLib.onPressLogin(
115
115
  props.dispatch,
116
116
  props.actions,
117
- props.server,
118
117
  props.app,
119
118
  props.apiUrl,
120
119
  props.language,
package/login.js CHANGED
@@ -2,7 +2,7 @@ import * as mgFunctionsLib from './functions.js';
2
2
  import * as mgConstantsLib from './constants.js';
3
3
  import axios from 'axios';
4
4
 
5
- export function onPressLogin(dispatch, actions, server, app, apiUrl, language, data) {
5
+ export function onPressLogin(dispatch, actions, app, apiUrl, language, data) {
6
6
  try {
7
7
  if (validateForm(data, language)) {
8
8
  let requestData = {
@@ -20,9 +20,13 @@ export function onPressLogin(dispatch, actions, server, app, apiUrl, language, d
20
20
  dispatch(actions.apiSuccess());
21
21
  })
22
22
  .catch(error => {
23
+
24
+ console.log(error.message);
25
+ console.log(error.code);
26
+ console.log(error.response);
27
+
23
28
  dispatch(actions.apiError());
24
- //mgFunctionsLib.showToastError(mgFunctionsLib.i18nMessage('credentialsInvalid', language));
25
- mgFunctionsLib.showToastError(error.message + ' - ' + error.code + ' - ' + error.status);
29
+ mgFunctionsLib.showToastError(mgFunctionsLib.i18nMessage('credentialsInvalid', language));
26
30
  })
27
31
  }
28
32
  } catch (error) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mg-library",
3
- "version": "1.0.386",
3
+ "version": "1.0.388",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {