Skip to content

Commit

Permalink
修复email配置文件的读取问题
Browse files Browse the repository at this point in the history
  • Loading branch information
CoderIvan committed Jan 5, 2024
1 parent dcdda7c commit 1cda08a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/email.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const nodemailer = require('nodemailer')
const fs = require('fs/promises')
const fs = require('fs')
const path = require('path')

const config = require('../config')
Expand All @@ -9,7 +9,7 @@ async function getEmailConfig(name, tag) {
const file = path.join(__dirname, '..', 'dockerfiles', name, tag, 'email.js')

try {
await fs.access(file, fs.constants.R_OK)
await fs.promises.access(file, fs.constants.R_OK)
logger.log('[Email Config]', 'can access')
} catch (err) {
logger.log('[Email Config]', 'can not access', err)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aliyun-docker-trigger",
"version": "1.2.1",
"version": "1.2.2",
"description": "",
"main": "index.js",
"author": "",
Expand Down

0 comments on commit 1cda08a

Please sign in to comment.