File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed
Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -1995,15 +1995,12 @@ function $CompileProvider($provide, $$sanitizeUriProvider) {
19951995
19961996 var controllerInstance = $controller ( controller , locals , true , directive . controllerAs ) ;
19971997
1998- // For directives with element transclusion the element is a comment,
1999- // but jQuery .data doesn't support attaching data to comment nodes as it's hard to
2000- // clean up (http://bugs.jquery.com/ticket/8335).
1998+ // For directives with element transclusion the element is a comment.
1999+ // In this case .data will not attach any data.
20012000 // Instead, we save the controllers for the element in a local hash and attach to .data
20022001 // later, once we have the actual element.
20032002 elementControllers [ directive . name ] = controllerInstance ;
2004- if ( ! hasElementTranscludeDirective ) {
2005- $element . data ( '$' + directive . name + 'Controller' , controllerInstance . instance ) ;
2006- }
2003+ $element . data ( '$' + directive . name + 'Controller' , controllerInstance . instance ) ;
20072004 }
20082005 return elementControllers ;
20092006 }
You can’t perform that action at this time.
0 commit comments