@webitel/api-services 0.0.60 → 0.0.61

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": "@webitel/api-services",
3
- "version": "0.0.60",
3
+ "version": "0.0.61",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "make-all": "npm run gen:api && npm version patch && (npm run build:types || true) && (npm run format:all || true) && npm run publish-lib",
@@ -70,12 +70,14 @@ export const downloadMedia = async (id) => {
70
70
  };
71
71
 
72
72
  export const downloadFile = (id) => {
73
- const url = `${baseUrl}/storage/file/${id}/download?access_token=${token}`;
73
+ const accessToken = localStorage.getItem('access-token'); // after auth token variable is null
74
+ const url = `${baseUrl}/storage/file/${id}/download?access_token=${accessToken}`;
74
75
  window.open(url, '_blank');
75
76
  };
76
77
 
77
78
  export const getScreenRecordingMediaUrl = (id, isThumb = false) => {
78
- const url = `${baseUrl}/storage/file/${id}/stream?access_token=${token}&fetch_thumbnail=${isThumb}`;
79
+ const accessToken = localStorage.getItem('access-token'); // after auth token variable is null
80
+ const url = `${baseUrl}/storage/file/${id}/stream?access_token=${accessToken}&fetch_thumbnail=${isThumb}`;
79
81
  return url;
80
82
  };
81
83
 
@@ -43,7 +43,8 @@ const getAdjunctTypesList = async (
43
43
  next,
44
44
  };
45
45
  } catch (err) {
46
- throw applyTransform(err, [notify]);
46
+ const errTransformers = silent ? [] : [notify];
47
+ throw applyTransform(err, errTransformers);
47
48
  }
48
49
  };
49
50
 
@@ -22,6 +22,7 @@ export * from './history/transcript/callTranscript';
22
22
  export * from './labels/labels';
23
23
  export * from './lists/blacklists';
24
24
  export * from './media/media';
25
+ export * from './messageService/messageService';
25
26
  export * from './object/object';
26
27
  export * from './pdfServices/pdfServices';
27
28
  export * from './phones/phones';
@@ -35,4 +36,3 @@ export * from './wtTypes/adjunctTypes/adjunctTypes';
35
36
  export * from './wtTypes/sysTypes/sysTypes';
36
37
  export * from './wtTypes/typeExtensions/typeExtensions';
37
38
  export * from './сontacts';
38
- export * from './messageService/messageService';