Skip to content

Commit 1b38cf9

Browse files
committed
0.9.0
1 parent 95ce860 commit 1b38cf9

3 files changed

Lines changed: 11 additions & 6 deletions

File tree

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "noderssbot",
3-
"version": "0.8.4",
3+
"version": "0.9.0",
44
"description": "Another Telegram RSSBot in Node.js",
55
"main": "dist/source",
66
"engines": {

source/config.ts

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,20 +21,25 @@ export const config: Config = {
2121
lang: process.env.RSSBOT_LANG || 'zh-cn',
2222
item_num: parseInt(process.env.RSSBOT_ITEM_NUM) || 10,
2323
fetch_gap: process.env.RSSBOT_FETCH_GAP || '5m',
24-
strict_ttl: !!process.env.RSSBOT_STRICT_TTL || true,
24+
strict_ttl:
25+
process.env.RSSBOT_STRICT_TTL !== '0' &&
26+
process.env.RSSBOT_STRICT_TTL !== 'false',
2527
notify_error_count: parseInt(process.env.NOTIFY_ERR_COUNT) || 5,
2628
view_all: !!process.env.RSSBOT_VIEW_ALL || false,
2729
UA:
2830
process.env.RSSBOT_UA ||
2931
`Mozilla/5.0 NodeRSSBot v${version}(https://github.com/fengkx/NodeRSSBot)`,
3032
not_send: !!process.env.NOT_SEND || false, // just for debug use
3133
concurrency: parseInt(process.env.RSSBOT_CONCURRENCY) || 200,
32-
delete_on_err_send: !!process.env.DELETE_ON_ERR_SEND || true, // block and chat not found
34+
delete_on_err_send:
35+
process.env.DELETE_ON_ERR_SEND !== '0' &&
36+
process.env.DELETE_ON_ERR_SEND !== 'false', // block and chat not found
3337
resp_timeout: parseInt(process.env.RSSBOT_RESP_TIMEOUT) || 40,
3438
allow_list: process.env.RSSBOT_ALLOW_LIST
3539
? process.env.RSSBOT_ALLOW_LIST.split(',').map((id) => Number(id))
3640
: null,
37-
auto_migrate: !!process.env.AUTO_MIGRATE || true
41+
auto_migrate:
42+
process.env.AUTO_MIGRATE !== '0' && process.env.AUTO_MIGRATE !== 'false'
3843
};
3944
Object.defineProperty(config, 'PKG_ROOT', {
4045
enumerable: false,

0 commit comments

Comments
 (0)