mirror of
https://github.com/whyour/qinglong.git
synced 2025-07-27 14:46:06 +08:00
按pr要求修改
This commit is contained in:
parent
08df6175ed
commit
510fad7ab6
|
@ -156,6 +156,7 @@ export default class NotificationService {
|
||||||
const url = matchResult && matchResult[1]
|
const url = matchResult && matchResult[1]
|
||||||
? `https://${matchResult[1]}.push.ft07.com/send/${serverChanKey}.send`
|
? `https://${matchResult[1]}.push.ft07.com/send/${serverChanKey}.send`
|
||||||
: `https://sctapi.ftqq.com/${serverChanKey}.send`;
|
: `https://sctapi.ftqq.com/${serverChanKey}.send`;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const res: any = await got
|
const res: any = await got
|
||||||
.post(url, {
|
.post(url, {
|
||||||
|
|
|
@ -228,7 +228,6 @@ function serverNotify(text, desp) {
|
||||||
if (PUSH_KEY) {
|
if (PUSH_KEY) {
|
||||||
// 微信server酱推送通知一个\n不会换行,需要两个\n才能换行,故做此替换
|
// 微信server酱推送通知一个\n不会换行,需要两个\n才能换行,故做此替换
|
||||||
desp = desp.replace(/[\n\r]/g, '\n\n');
|
desp = desp.replace(/[\n\r]/g, '\n\n');
|
||||||
|
|
||||||
const matchResult = PUSH_KEY.match(/^sctp(\d+)t/i);
|
const matchResult = PUSH_KEY.match(/^sctp(\d+)t/i);
|
||||||
const options = {
|
const options = {
|
||||||
url: matchResult && matchResult[1]
|
url: matchResult && matchResult[1]
|
||||||
|
|
Loading…
Reference in New Issue
Block a user