Skip to content

Commit

Permalink
Merge pull request #861 from philipnilsson/patch-1
Browse files Browse the repository at this point in the history
Fix NPE in babel, add a null check
  • Loading branch information
theKashey authored Feb 17, 2018
2 parents 8fa1d42 + 1a06535 commit 572e803
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/babel.dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ module.exports = function plugin(args) {
node[REGISTRATIONS] = null // eslint-disable-line no-param-reassign

// inject the code only if applicable
if (registrations.length) {
if (registrations && registrations.length) {
node.body.unshift(headerTemplate())
// Inject the generated tagging code at the very end
// so that it is as minimally intrusive as possible.
Expand Down

0 comments on commit 572e803

Please sign in to comment.