-
Notifications
You must be signed in to change notification settings - Fork 455
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
8 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,7 +12,9 @@ export const patchBabelCore_githubIssue6577: ModulePatcher<TBabelCore> = babel = | |
// This is a hack to bypass it and fix our issue #627 | ||
// The bug disallow debugging when using Babel Jest with [email protected] because of | ||
// source-maps not being inlined | ||
if (typeof babel.version === 'string' && semver.satisfies(babel.version, '>=6 <7')) { | ||
if (typeof babel.version !== 'string') return babel | ||
const version = semver.coerce(babel.version) | ||
if (version && version.major === 6) { | ||
try { | ||
const File = require('babel-core/lib/transformation/file').File | ||
File.prototype.initOptions = (original => { | ||
|