@ryuu-reinzz/haruka-lib 1.2.19 → 1.2.21

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/main/socket.js +8 -1
  2. package/package.json +1 -1
package/main/socket.js CHANGED
@@ -171,6 +171,7 @@ Object.assign(socket, {
171
171
  image = null,
172
172
  video = null,
173
173
  document = null,
174
+ fileName = null,
174
175
  mimetype = null,
175
176
  jpegThumbnail = null,
176
177
  location = null,
@@ -273,6 +274,12 @@ Object.assign(socket, {
273
274
  mediaInput.document = { url: document };
274
275
  }
275
276
 
277
+ if (fileName) {
278
+ if (typeof mediaInput.document === "object") {
279
+ mediaInput.document.fileName = fileName;
280
+ }
281
+ }
282
+
276
283
  if (mimetype) {
277
284
  if (typeof mediaInput.document === "object") {
278
285
  mediaInput.document.mimetype = mimetype;
@@ -391,7 +398,7 @@ Object.assign(socket, {
391
398
  mediaType: externalAdReply.mediaType || 1,
392
399
  sourceUrl: externalAdReply.sourceUrl || externalAdReply.url || "",
393
400
  thumbnailUrl:
394
- externalAdReply.thumbnailUrl || externalAdReply.thumbnail || "",
401
+ externalAdReply.thumbnailUrl || "",
395
402
  renderLargerThumbnail: externalAdReply.renderLargerThumbnail || false,
396
403
  showAdAttribution: externalAdReply.showAdAttribution !== false,
397
404
  containsAutoReply: externalAdReply.containsAutoReply || false,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ryuu-reinzz/haruka-lib",
3
- "version": "1.2.19",
3
+ "version": "1.2.21",
4
4
  "description": "Library extra for bot WhatsApp",
5
5
  "main": "main/index.js",
6
6
  "type": "module",