File tree 1 file changed +3
-6
lines changed
1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -2333,15 +2333,12 @@ function $CompileProvider($provide, $$sanitizeUriProvider) {
2333
2333
2334
2334
var controllerInstance = $controller ( controller , locals , true , directive . controllerAs ) ;
2335
2335
2336
- // For directives with element transclusion the element is a comment,
2337
- // but jQuery .data doesn't support attaching data to comment nodes as it's hard to
2338
- // clean up (http://bugs.jquery.com/ticket/8335).
2336
+ // For directives with element transclusion the element is a comment.
2337
+ // In this case .data will not attach any data.
2339
2338
// Instead, we save the controllers for the element in a local hash and attach to .data
2340
2339
// later, once we have the actual element.
2341
2340
elementControllers [ directive . name ] = controllerInstance ;
2342
- if ( ! hasElementTranscludeDirective ) {
2343
- $element . data ( '$' + directive . name + 'Controller' , controllerInstance . instance ) ;
2344
- }
2341
+ $element . data ( '$' + directive . name + 'Controller' , controllerInstance . instance ) ;
2345
2342
}
2346
2343
return elementControllers ;
2347
2344
}
You can’t perform that action at this time.
0 commit comments