@edraj/tsdmart 1.0.14 → 1.0.15

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 (2) hide show
  1. package/index.ts +22 -22
  2. package/package.json +1 -1
package/index.ts CHANGED
@@ -333,7 +333,7 @@ export default class Dmart {
333
333
  >(`${this.baseURL}/user/login`, {shortname, password}, {headers});
334
334
  return data;
335
335
  } catch (error: any) {
336
- throw new Error(error.response.data.error)
336
+ throw new Error(error.response.data)
337
337
  }
338
338
  }
339
339
 
@@ -344,7 +344,7 @@ export default class Dmart {
344
344
  >(`${this.baseURL}/user/login`, {...credentials, password}, {headers});
345
345
  return data;
346
346
  } catch (error: any) {
347
- throw new Error(error.response.data.error)
347
+ throw new Error(error.response.data)
348
348
  }
349
349
  }
350
350
 
@@ -357,7 +357,7 @@ export default class Dmart {
357
357
  );
358
358
  return data;
359
359
  } catch (error: any) {
360
- throw new Error(error.response.data.error)
360
+ throw new Error(error.response.data)
361
361
  }
362
362
  }
363
363
 
@@ -370,7 +370,7 @@ export default class Dmart {
370
370
  );
371
371
  return data;
372
372
  } catch (error: any) {
373
- throw new Error(error.response.data.error)
373
+ throw new Error(error.response.data)
374
374
  }
375
375
  }
376
376
 
@@ -383,7 +383,7 @@ export default class Dmart {
383
383
  );
384
384
  return data;
385
385
  } catch (error: any) {
386
- throw new Error(error.response.data.error)
386
+ throw new Error(error.response.data)
387
387
  }
388
388
  }
389
389
 
@@ -395,7 +395,7 @@ export default class Dmart {
395
395
  );
396
396
  return data;
397
397
  } catch (error: any) {
398
- throw new Error(error.response.data.error)
398
+ throw new Error(error.response.data)
399
399
  }
400
400
  }
401
401
 
@@ -419,7 +419,7 @@ export default class Dmart {
419
419
  }
420
420
  return data;
421
421
  } catch (error: any) {
422
- throw new Error(error.response.data.error)
422
+ throw new Error(error.response.data)
423
423
  }
424
424
  }
425
425
 
@@ -437,7 +437,7 @@ export default class Dmart {
437
437
  );
438
438
  return data;
439
439
  } catch (error: any) {
440
- throw new Error(error.response.data.error)
440
+ throw new Error(error.response.data)
441
441
  }
442
442
  }
443
443
 
@@ -453,7 +453,7 @@ export default class Dmart {
453
453
  );
454
454
  return data;
455
455
  } catch (error: any) {
456
- throw new Error(error.response.data.error)
456
+ throw new Error(error.response.data)
457
457
  }
458
458
  }
459
459
 
@@ -466,7 +466,7 @@ export default class Dmart {
466
466
  );
467
467
  return data;
468
468
  } catch (error: any) {
469
- throw new Error(error.response.data.error)
469
+ throw new Error(error.response.data)
470
470
  }
471
471
  }
472
472
 
@@ -479,7 +479,7 @@ export default class Dmart {
479
479
  );
480
480
  return data;
481
481
  } catch (error: any) {
482
- throw new Error(error.response.data.error)
482
+ throw new Error(error.response.data)
483
483
  }
484
484
  }
485
485
 
@@ -502,7 +502,7 @@ export default class Dmart {
502
502
  );
503
503
  return data;
504
504
  } catch (error: any) {
505
- throw new Error(error.response.data.error)
505
+ throw new Error(error.response.data)
506
506
  }
507
507
  }
508
508
 
@@ -551,7 +551,7 @@ export default class Dmart {
551
551
 
552
552
  return data;
553
553
  } catch (error: any) {
554
- throw new Error(error.response.data.error)
554
+ throw new Error(error.response.data)
555
555
  }
556
556
  }
557
557
 
@@ -584,7 +584,7 @@ export default class Dmart {
584
584
  );
585
585
  return data;
586
586
  } catch (error: any) {
587
- throw new Error(error.response.data.error)
587
+ throw new Error(error.response.data)
588
588
  }
589
589
  }
590
590
 
@@ -641,7 +641,7 @@ export default class Dmart {
641
641
  >(`${this.baseURL}/managed/health/${space_name}`, {headers});
642
642
  return data;
643
643
  } catch (error: any) {
644
- throw new Error(error.response.data.error)
644
+ throw new Error(error.response.data)
645
645
  }
646
646
  }
647
647
 
@@ -659,7 +659,7 @@ export default class Dmart {
659
659
  );
660
660
  return data;
661
661
  } catch (error: any) {
662
- throw new Error(error.response.data.error)
662
+ throw new Error(error.response.data)
663
663
  }
664
664
  }
665
665
 
@@ -678,7 +678,7 @@ export default class Dmart {
678
678
  );
679
679
  return data;
680
680
  } catch (error: any) {
681
- throw new Error(error.response.data.error)
681
+ throw new Error(error.response.data)
682
682
  }
683
683
  }
684
684
 
@@ -697,7 +697,7 @@ export default class Dmart {
697
697
  );
698
698
  return data;
699
699
  }catch (error: any) {
700
- throw new Error(error.response.data.error)
700
+ throw new Error(error.response.data)
701
701
  }
702
702
  }
703
703
 
@@ -726,7 +726,7 @@ export default class Dmart {
726
726
  );
727
727
  return data;
728
728
  } catch (error: any) {
729
- throw new Error(error.response.data.error)
729
+ throw new Error(error.response.data)
730
730
  }
731
731
  }
732
732
 
@@ -744,7 +744,7 @@ export default class Dmart {
744
744
  );
745
745
  return data;
746
746
  } catch (error: any) {
747
- throw new Error(error.response.data.error)
747
+ throw new Error(error.response.data)
748
748
  }
749
749
  }
750
750
 
@@ -755,7 +755,7 @@ export default class Dmart {
755
755
  });
756
756
  return data;
757
757
  } catch (error: any) {
758
- throw new Error(error.response.data.error)
758
+ throw new Error(error.response.data)
759
759
  }
760
760
  }
761
761
 
@@ -766,7 +766,7 @@ export default class Dmart {
766
766
  });
767
767
  return data;
768
768
  } catch (error: any) {
769
- throw new Error(error.response.data.error)
769
+ throw new Error(error.response.data)
770
770
  }
771
771
  }
772
772
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@edraj/tsdmart",
3
- "version": "1.0.14",
3
+ "version": "1.0.15",
4
4
  "description": "A TypeScript implementation of the Dmart that depends on axios.",
5
5
  "author": "Kefah T. Issa",
6
6
  "email": "kefah.issa@gmail.com",