Skip to content
This repository has been archived by the owner on Aug 25, 2022. It is now read-only.

Commit

Permalink
refine: use lodash instead
Browse files Browse the repository at this point in the history
  • Loading branch information
SamuelZhaoY committed Dec 18, 2019
1 parent 82291bf commit e5007cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/crawler/ocr-impl/ocr-crawler.js
Expand Up @@ -297,7 +297,7 @@ NSCrawler.prototype.recursiveFilter = function (source, matches) {
// check if current source contains head bar
let shift_items = 0;
for (const line of source.lines) {
if (line.line && line.line[0].bbox.y0 < estimatedStatusAndNavBarHeight / DPTOPXRatio) {
if (_.get(line, 'line[0].bbox.y0') < estimatedStatusAndNavBarHeight / DPTOPXRatio) {
shift_items++;
}
}
Expand Down

0 comments on commit e5007cf

Please sign in to comment.