diff --git a/config/index.js b/config/index.js index 3e097b47be8..ea95720876d 100644 --- a/config/index.js +++ b/config/index.js @@ -12,15 +12,15 @@ module.exports = { process.env.RSSBOT_DB_PATH || path.join(__dirname, '../data/database.db'), lang: process.env.RSSBOT_LANG || 'zh-cn', - item_num: process.env.RSSBOT_ITEM_NUM || 10, + item_num: parseInt(process.env.RSSBOT_ITEM_NUM) || 10, fetch_gap: process.env.RSSBOT_FETCH_GAP || '5m', - notify_error_count: process.env.NOTIFY_ERR_COUNT || 5, + notify_error_count: parseInt(process.env.NOTIFY_ERR_COUNT) || 5, view_all: !!process.env.RSSBOT_VIEW_ALL || false, UA: process.env.RSSBOT_UA || `Mozilla/5.0 NodeRSSBot v${version}(https://github.com/fengkx/NodeRSSBot)`, not_send: process.env.NOT_SEND || false, // just for debug use - concurrency: process.env.RSSBOT_CONCURRENCY || 200, + concurrency: parseInt(process.env.RSSBOT_CONCURRENCY) || 200, delete_on_err_send: process.env.DELETE_ON_ERR_SEND || true, // block and chat not found - resp_timeout: process.env.RSSBOT_RESP_TIMEOUT || 40 + resp_timeout: parseInt(process.env.RSSBOT_RESP_TIMEOUT) || 40 };