File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -345,9 +345,9 @@ export const overrideFormMethod = (
345345 * either constructed or appended from a DocumentFragment
346346 * @param ref {HTMLElement} - The custom element to upgrade
347347 */
348- export const upgradeInternals = ( ref : FormAssociatedCustomElement ) => {
348+ export const upgradeInternals = ( ref : FormAssociatedCustomElement ) : boolean => {
349+ let attached = false ;
349350 if ( ref . constructor [ "formAssociated" ] ) {
350- let attached = false ;
351351 let internals = internalsMap . get ( ref ) ;
352352 // we might have cases where the internals are not set
353353 if ( internals === undefined ) {
@@ -358,8 +358,8 @@ export const upgradeInternals = (ref: FormAssociatedCustomElement) => {
358358 const { labels, form } = internals ;
359359 initLabels ( ref , labels ) ;
360360 initForm ( ref , form , internals ) ;
361- return attached ;
362361 }
362+ return attached ;
363363} ;
364364
365365/**
You can’t perform that action at this time.
0 commit comments