Skip to content

Commit

Permalink
Fix a bug when extract data from #foreach statement.
Browse files Browse the repository at this point in the history
  • Loading branch information
fool2fish committed Jun 30, 2014
1 parent bf77e20 commit c951426
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions lib/data/data-direc.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,16 @@ module.exports = {
}

o = rightr.__value
if (!utilx.isArray(o)) leftr = BREAK
if (!node.body) return
if (!o[0]) o[0] = { __stats: STATS.UNCERTAIN }
leftr = {
__stats: STATS.LEFT,
__value: o[0]
if (utilx.isArray(o)) {
if (!node.body) return
if (!o[0]) o[0] = { __stats: STATS.UNCERTAIN }
leftr = {
__stats: STATS.LEFT,
__value: o[0]
}
} else {
leftr = BREAK
}
}

} else {
leftr = BREAK
Expand Down

0 comments on commit c951426

Please sign in to comment.