diff options
| author | Igor Minar | 2011-01-19 21:47:14 -0800 |
|---|---|---|
| committer | Igor Minar | 2011-01-19 21:47:14 -0800 |
| commit | 17ee0f031ac4a37bf9a1dc8c87ffac4bd164d1cc (patch) | |
| tree | db799a01074f9b389fc4c069189150381d075df6 /src | |
| parent | 10646c9f6f62dd5130606d07ffe69770b3973f47 (diff) | |
| download | angular.js-17ee0f031ac4a37bf9a1dc8c87ffac4bd164d1cc.tar.bz2 | |
fix ng:include issue introduced by a5eb3ed1
Diffstat (limited to 'src')
| -rw-r--r-- | src/widgets.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/widgets.js b/src/widgets.js index 4585629a..1ab8a2c9 100644 --- a/src/widgets.js +++ b/src/widgets.js @@ -635,7 +635,12 @@ angularWidget('ng:include', function(element){ if (src) { xhr('GET', src, function(code, response){ element.html(response); - childScope = useScope || createScope(scope); + if (useScope) { + childScope = useScope; + } else { + childScope = createScope(scope); + scope.$onEval(childScope.$eval); + } compiler.compile(element)(element, childScope); childScope.$init(); scope.$eval(onloadExp); |
