ywana-core8 0.1.24 → 0.1.25

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ywana-core8",
3
- "version": "0.1.24",
3
+ "version": "0.1.25",
4
4
  "description": "ywana-core8",
5
5
  "homepage": "https://ywana.github.io/workspace",
6
6
  "author": "Ernesto Roldan Garcia",
@@ -16,18 +16,22 @@ async function fetchAsync(method, URL, body = null, token, headers) {
16
16
  if (headers) request.headers = request.headers
17
17
 
18
18
  try {
19
+
19
20
  var response = await fetch(URL, request);
20
21
  if (response.ok) {
21
22
  const json = await response.json();
22
23
  return json
23
24
  }
24
25
  throw response
25
- } catch (error) {
26
- if (error instanceof Error) { throw { error } }
27
- const json = await error.json()
26
+
27
+ } catch (response) {
28
+ if (response instanceof response) { throw { response } }
29
+ const json = await response.json()
28
30
  throw {
29
31
  success: false,
30
- message: json.message || json.err
32
+ message: json.message || json.err,
33
+ status: response.status,
34
+ statusText: response.statusText,
31
35
  }
32
36
  }
33
37
  }
@@ -21,7 +21,7 @@ export const ResetPasswordBoxTest = (prop) => {
21
21
  return (
22
22
  <ResetPasswordBox {...config} >
23
23
  <div>
24
- <p>Your password must contain</p>
24
+ <h5>Your password must contain</h5>
25
25
  <ul>
26
26
  <li>At least 8 characters</li>
27
27
  <li>At least one uppercase letter</li>