• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1'use strict'
2
3var childPath = require('../utils/child-path.js')
4var reset = require('./node.js').reset
5
6module.exports = function inflateBundled (bundler, parent, children) {
7  children.forEach(function (child) {
8    if (child.fromBundle === bundler) return
9    reset(child)
10    child.fromBundle = bundler
11    child.isInLink = bundler.isLink
12    child.parent = parent
13    child.path = childPath(parent.path, child)
14    child.realpath = bundler.isLink ? child.realpath : childPath(parent.realpath, child)
15    child.isLink = child.isLink || parent.isLink || parent.target
16    inflateBundled(bundler, child, child.children)
17  })
18}
19