Skip to content

Commit

Permalink
ci: fix
Browse files Browse the repository at this point in the history
  • Loading branch information
luoingly committed Feb 24, 2025
1 parent f3ea847 commit 813b10f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion config/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ config.deploy = {
adminInitPwd: 'kplkplkpl',
}

config.secretKey = process.env.secretKey
config.secretKey = process.env.secretKey || ''

config.dbURL = process.env.DBURL || process.env.dbURL // 之所以两个只为了兼容旧版命名;请优先采用后者

Expand Down
4 changes: 2 additions & 2 deletions config/website.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ const process = require('node:process')

module.exports = {
title: process.env.title || 'Putong OJ',
discussOnProblem: process.env.discussOnProblem == null ? false : process.env.discussOnProblem.toLocaleLowerCase() === 'true',
semi_restful: process.env.semiRestful == null ? false : process.env.semiRestful.toLocaleLowerCase() === 'true',
discussOnProblem: (process.env.discussOnProblem || 'false').toLocaleLowerCase() === 'true',
semi_restful: (process.env.semiRestful || 'false').toLocaleLowerCase() === 'true',
}

/**
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"deploy:init": "cross-env NODE_ENV=production node manage.js",
"deploy:start": "npx pm2 start pm2.config.json",
"pretest": "cross-env NODE_ENV=test node test/pretest.js",
"test": "cross-env NODE_ENV=test node test/pretest.js && nyc ava && node test/posttest.js",
"test": "cross-env-shell NODE_ENV=test \"node test/pretest.js && nyc ava && node test/posttest.js\"",
"report": "nyc report --reporter=html",
"posttest": "cross-env NODE_ENV=test node test/posttest.js",
"lint": "eslint .",
Expand Down

0 comments on commit 813b10f

Please sign in to comment.