@swan-admin/swan-ai-measurements 1.0.91 → 1.0.92

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.
@@ -150,9 +150,7 @@ class FileUpload {
150
150
  },
151
151
  throwError: true,
152
152
  });
153
- console.log(res, "res for start");
154
153
  const totalChunks = getFileChunks(file);
155
- console.log(totalChunks, "total chunks");
156
154
  const parts = [];
157
155
  for (let i = 0; i < totalChunks.length; i++) {
158
156
  const data = yield fetchData({
@@ -165,14 +163,12 @@ class FileUpload {
165
163
  },
166
164
  throwError: true,
167
165
  });
168
- console.log(data, "data for signed url");
169
166
  const val = yield axios.put(data === null || data === void 0 ? void 0 : data.url, totalChunks[i], {
170
167
  headers: { "Content-Type": file.type, "X-Api-Key": __classPrivateFieldGet(this, _FileUpload_accessKey, "f") },
171
168
  });
172
169
  parts.push({ PartNumber: i + 1, ETag: '"958057f9cd1d264e94fcc0d2ccabc09f"' });
173
- console.log(val === null || val === void 0 ? void 0 : val.data, "after uploading");
170
+ console.log(val, "after uploading");
174
171
  }
175
- console.log(parts, "parts");
176
172
  const completeValue = yield fetchData({
177
173
  path: FILE_UPLOAD_ENDPOINT.UPLOAD_COMPLETE,
178
174
  apiKey: __classPrivateFieldGet(this, _FileUpload_accessKey, "f"),
@@ -184,7 +180,6 @@ class FileUpload {
184
180
  },
185
181
  throwError: true,
186
182
  });
187
- console.log(completeValue, "after complete");
188
183
  resolve({ message: "successfully uploaded", data: completeValue });
189
184
  } catch (error) {
190
185
  reject(error);
@@ -100,9 +100,7 @@ class FileUpload {
100
100
  },
101
101
  throwError: true,
102
102
  });
103
- console.log(res, "res for start");
104
103
  const totalChunks = (0, utils_js_1.getFileChunks)(file);
105
- console.log(totalChunks, "total chunks");
106
104
  const parts = [];
107
105
  for (let i = 0; i < totalChunks.length; i++) {
108
106
  const data = await (0, utils_js_1.fetchData)({
@@ -115,12 +113,10 @@ class FileUpload {
115
113
  },
116
114
  throwError: true,
117
115
  });
118
- console.log(data, "data for signed url");
119
116
  const val = await axios_1.default.put(data?.url, totalChunks[i], { headers: { "Content-Type": file.type, "X-Api-Key": this.#accessKey } });
120
117
  parts.push({ PartNumber: i + 1, ETag: '"958057f9cd1d264e94fcc0d2ccabc09f"' });
121
- console.log(val?.data, "after uploading");
118
+ console.log(val, "after uploading");
122
119
  }
123
- console.log(parts, "parts");
124
120
  const completeValue = await (0, utils_js_1.fetchData)({
125
121
  path: constants_js_1.FILE_UPLOAD_ENDPOINT.UPLOAD_COMPLETE,
126
122
  apiKey: this.#accessKey,
@@ -132,7 +128,6 @@ class FileUpload {
132
128
  },
133
129
  throwError: true,
134
130
  });
135
- console.log(completeValue, "after complete");
136
131
  resolve({ message: "successfully uploaded", data: completeValue });
137
132
  }
138
133
  catch (error) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swan-admin/swan-ai-measurements",
3
- "version": "1.0.91",
3
+ "version": "1.0.92",
4
4
  "description": "provides ai measurement suggestion",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/esm/index.js",
package/src/fileUpload.ts CHANGED
@@ -122,9 +122,7 @@ export default class FileUpload {
122
122
  },
123
123
  throwError: true,
124
124
  });
125
- console.log(res, "res for start");
126
125
  const totalChunks = getFileChunks(file);
127
- console.log(totalChunks, "total chunks");
128
126
  const parts = [];
129
127
  for (let i = 0; i < totalChunks.length; i++) {
130
128
  const data: { url: string } = await fetchData({
@@ -137,12 +135,10 @@ export default class FileUpload {
137
135
  },
138
136
  throwError: true,
139
137
  });
140
- console.log(data, "data for signed url");
141
138
  const val = await axios.put(data?.url, totalChunks[i], { headers: { "Content-Type": file.type, "X-Api-Key": this.#accessKey } });
142
139
  parts.push({ PartNumber: i + 1, ETag: '"958057f9cd1d264e94fcc0d2ccabc09f"' });
143
- console.log(val?.data, "after uploading");
140
+ console.log(val, "after uploading");
144
141
  }
145
- console.log(parts, "parts");
146
142
  const completeValue = await fetchData({
147
143
  path: FILE_UPLOAD_ENDPOINT.UPLOAD_COMPLETE,
148
144
  apiKey: this.#accessKey,
@@ -154,8 +150,6 @@ export default class FileUpload {
154
150
  },
155
151
  throwError: true,
156
152
  });
157
- console.log(completeValue, "after complete");
158
-
159
153
  resolve({ message: "successfully uploaded", data: completeValue });
160
154
  } catch (error: any) {
161
155
  reject(error);