Skip to content

Commit

Permalink
[core] Fix return
Browse files Browse the repository at this point in the history
  • Loading branch information
kybarg committed Feb 22, 2018
1 parent 5c87caa commit 0e53a1e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion lib/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 3 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-qr-scanner",
"version": "0.0.3",
"version": "0.0.4",
"description": "A react component for reading QR codes from the webcam.",
"main": "./lib/index.js",
"scripts": {
Expand Down Expand Up @@ -39,11 +39,8 @@
"gulp-concat": "^2.6.1",
"gulp-inline-str": "^0.1.0",
"gulp-uglify": "^2.0.0",
"react": "^15.0.2"
},
"peerDependencies": {
"react": "^15.0.2",
"react-dom": "^15.0.2"
"react": "15.6.2",
"react-dom": "15.6.2"
},
"dependencies": {
"jsqr": "^1.0.1",
Expand Down
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ module.exports = class Reader extends Component {
const { onScan, legacyMode, delay } = this.props
const decoded = e.data

onScan(decoded || null)
onScan(decoded.data || null)

if (!legacyMode && typeof delay == 'number' && this.worker) {
this.timeout = setTimeout(this.check, delay)
Expand Down

0 comments on commit 0e53a1e

Please sign in to comment.