Commit 7e929c28 by trace

fix: 每跑一轮都通知的 issue

parent c209fe6f
...@@ -170,7 +170,10 @@ async function startMonitor() { ...@@ -170,7 +170,10 @@ async function startMonitor() {
log(`抓取一圈`) log(`抓取一圈`)
await getConfig() await getConfig()
.then(() => { // 部署通知, 更新说明 .then(() => { // 部署通知, 更新说明
sendEmail(`<div>爬虫部署版本: ${version}</div>更新说明: ${release}`) if (newDeploy) {
sendEmail(`<div>爬虫部署版本: ${version}</div>更新说明: ${release}`)
newDeploy = false
}
}) })
.then(getDaichao) .then(getDaichao)
.then(getTop100) .then(getTop100)
...@@ -243,7 +246,7 @@ function generateDailyOnlineReport() { ...@@ -243,7 +246,7 @@ function generateDailyOnlineReport() {
async function getDaichao() { async function getDaichao() {
let allRegionDaichaoApps = [] let allRegionDaichaoApps = []
for (region in daichaoRegion) { for (region in daichaoRegion) {
// for (index in Object.keys(daichaoRegion)) { // for (index in Object.keys(daichaoRegion)) {
// let region = daichaoRegion[index] // let region = daichaoRegion[index]
daichaoApiUrl = region + daichao daichaoApiUrl = region + daichao
log(` 贷超 url: ${daichaoApiUrl}`) log(` 贷超 url: ${daichaoApiUrl}`)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment