@mathrunet/masamune 1.8.4 → 1.8.5
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/CHANGELOG.md +9 -0
- package/dist/lib/send_grid.js +6 -3
- package/dist/lib/send_grid.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,12 @@
|
|
|
1
|
+
## [1.8.5](https://github.com/mathrunet/node_masamune/compare/v1.8.4...v1.8.5) (2023-11-29)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### fix
|
|
5
|
+
|
|
6
|
+
* Fixed Sendgrid bug. ([c9baa20](https://github.com/mathrunet/node_masamune/commit/c9baa2061aaccfa753d3cf948c814ec56494d178))
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
1
10
|
## [1.8.4](https://github.com/mathrunet/node_masamune/compare/v1.8.3...v1.8.4) (2023-11-28)
|
|
2
11
|
|
|
3
12
|
|
package/dist/lib/send_grid.js
CHANGED
|
@@ -31,10 +31,13 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
31
31
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
32
32
|
});
|
|
33
33
|
};
|
|
34
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
35
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
36
|
+
};
|
|
34
37
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
35
38
|
exports.send = void 0;
|
|
36
39
|
const functions = __importStar(require("firebase-functions"));
|
|
37
|
-
const
|
|
40
|
+
const mail_1 = __importDefault(require("@sendgrid/mail"));
|
|
38
41
|
/**
|
|
39
42
|
* Send mail through SendGrid.
|
|
40
43
|
*
|
|
@@ -65,14 +68,14 @@ const sendgrid = __importStar(require("@sendgrid/mail"));
|
|
|
65
68
|
function send({ from, to, title, content, }) {
|
|
66
69
|
return __awaiter(this, void 0, void 0, function* () {
|
|
67
70
|
const config = functions.config().mail;
|
|
68
|
-
|
|
71
|
+
mail_1.default.setApiKey(config.sendgrid.api_key);
|
|
69
72
|
const msg = {
|
|
70
73
|
to: to,
|
|
71
74
|
from: from,
|
|
72
75
|
subject: title,
|
|
73
76
|
text: content,
|
|
74
77
|
};
|
|
75
|
-
yield
|
|
78
|
+
yield mail_1.default.send(msg);
|
|
76
79
|
});
|
|
77
80
|
}
|
|
78
81
|
exports.send = send;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"send_grid.js","sourceRoot":"","sources":["../../src/lib/send_grid.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"send_grid.js","sourceRoot":"","sources":["../../src/lib/send_grid.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,8DAAgD;AAChD,0DAAsC;AAEtC;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,SAAsB,IAAI,CAAC,EACzB,IAAI,EACJ,EAAE,EACF,KAAK,EACL,OAAO,GAMR;;QACC,MAAM,MAAM,GAAG,SAAS,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC;QACvC,cAAQ,CAAC,SAAS,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;QAC5C,MAAM,GAAG,GAAG;YACV,EAAE,EAAE,EAAE;YACN,IAAI,EAAE,IAAI;YACV,OAAO,EAAE,KAAK;YACd,IAAI,EAAE,OAAO;SACd,CAAC;QACF,MAAM,cAAQ,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAC3B,CAAC;CAAA;AApBD,oBAoBC"}
|