Skip to content

Commit

Permalink
fix: Reverted file-type update
Browse files Browse the repository at this point in the history
  • Loading branch information
edgardmessias committed Nov 26, 2021
1 parent c5c6667 commit d665164
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ updates:
- dependency-name: '@types/node'
versions:
- '>= 15.a'
- dependency-name: 'file-type'
versions:
- '>= 17.a'
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
"name": "@wppconnect/wa-js",
"version": "1.0.14",
"description": "WPPConnect/WA-JS is an open-source project with the aim of exporting functions from WhatsApp Web",
"main": "dist/wppconnect-wa.js",
"types": "dist/index.d.ts",
"exports": {
".": "./dist/wppconnect-wa.js"
Expand Down Expand Up @@ -58,7 +57,7 @@
"eslint-plugin-import": "^2.25.3",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-simple-import-sort": "^7.0.0",
"file-type": "^17.0.0",
"file-type": "~16.5.3",
"husky": "^7.0.4",
"playwright-chromium": "^1.16.3",
"prettier": "^2.5.0",
Expand Down
2 changes: 1 addition & 1 deletion src/chat/Chat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -809,7 +809,7 @@ export class Chat extends Emittery<ChatEventTypes> {
);

if (!filename) {
const result = await FileType.fileTypeFromBuffer(buffer);
const result = await FileType.fromBuffer(buffer);
if (result) {
const baseType = result.mime.split('/')[0];
filename = `${baseType}.${result.ext}`;
Expand Down

0 comments on commit d665164

Please sign in to comment.