Skip to content

Commit

Permalink
rss: bangumi calendar today: fix undefine and null
Browse files Browse the repository at this point in the history
  • Loading branch information
DIYgod committed May 21, 2018
1 parent 826364e commit 1529669
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion routes/bangumi/calendar/_base.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = async (ctx) => {
const cache = await Promise.all(url.map(ctx.cache.get));
const result = await Promise.all(
cache.map(async (c, i) => {
if (c !== undefined) {
if (c) {
return Promise.resolve(JSON.parse(c));
} else {
const response = await axios({
Expand Down

0 comments on commit 1529669

Please sign in to comment.