File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed
src/material/autocomplete Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -767,8 +767,15 @@ export class MatAutocompleteTrigger
767767 }
768768
769769 private _attachOverlay ( valueOnAttach : string ) : void {
770- if ( ! this . autocomplete && ( typeof ngDevMode === 'undefined' || ngDevMode ) ) {
771- throw getMatAutocompleteMissingPanelError ( ) ;
770+ if ( ! this . autocomplete ) {
771+ if ( typeof ngDevMode === 'undefined' || ngDevMode ) {
772+ throw getMatAutocompleteMissingPanelError ( ) ;
773+ } else {
774+ // This shouldn't happen only in production mode, but some internal teams have
775+ // observed it in their production logging. Return since the rest of the function
776+ // assumes that the autocomplete is defined.
777+ return ;
778+ }
772779 }
773780
774781 let overlayRef = this . _overlayRef ;
You can’t perform that action at this time.
0 commit comments