@postalsys/email-text-tools 1.2.5 → 1.2.7

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.
@@ -5,7 +5,7 @@ const htmlToText = require('../lib/html-to-text');
5
5
  const nodeFetch = require('node-fetch');
6
6
  const fetchCmd = global.fetch || nodeFetch;
7
7
 
8
- const MAX_TEXT_LENGTH = 6 * 1024;
8
+ const MAX_TEXT_LENGTH = 4 * 1024;
9
9
  const OPENAI_API_URL = 'https://api.openai.com/v1/chat/completions';
10
10
 
11
11
  const SYSTEM_PROMPT = `
@@ -80,11 +80,6 @@ ${text}`
80
80
 
81
81
  let data = await res.json();
82
82
 
83
- console.log(`-----
84
- ${text}
85
- ----
86
- ${JSON.stringify(data)}`);
87
-
88
83
  if (!res.ok) {
89
84
  if (data && data.error) {
90
85
  let error = new Error(data.error.message || data.error);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@postalsys/email-text-tools",
3
- "version": "1.2.5",
3
+ "version": "1.2.7",
4
4
  "description": "Email text tools",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -19,21 +19,21 @@
19
19
  "homepage": "https://github.com/postalsys/email-text-tools#readme",
20
20
  "devDependencies": {
21
21
  "eslint-config-nodemailer": "1.2.0",
22
- "eslint-config-prettier": "8.7.0",
22
+ "eslint-config-prettier": "8.8.0",
23
23
  "mailparser": "3.6.4"
24
24
  },
25
25
  "dependencies": {
26
26
  "dompurify": "3.0.1",
27
27
  "handlebars": "4.7.7",
28
28
  "he": "1.2.0",
29
- "html-to-text": "9.0.4",
29
+ "html-to-text": "9.0.5",
30
30
  "js-beautify": "1.14.7",
31
- "jsdom": "21.1.0",
32
- "juice": "8.1.0",
31
+ "jsdom": "21.1.1",
32
+ "juice": "9.0.0",
33
33
  "linkify-it": "4.0.1",
34
- "moment-timezone": "0.5.41",
34
+ "moment-timezone": "0.5.43",
35
35
  "node-fetch": "2.6.7",
36
36
  "node-html-parser": "6.1.5",
37
- "tlds": "1.237.0"
37
+ "tlds": "1.238.0"
38
38
  }
39
39
  }