From a2d91e4674ce04642004e6bd288be25ee7d34f87 Mon Sep 17 00:00:00 2001 From: Amit Gharat Date: Wed, 19 Jun 2019 23:13:44 +0530 Subject: [PATCH] chore(button): re-use common function for getting native element (#16056) --- src/material/button/button.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/material/button/button.ts b/src/material/button/button.ts index 261e3133f031..1f2bede9d2da 100644 --- a/src/material/button/button.ts +++ b/src/material/button/button.ts @@ -98,7 +98,7 @@ export class MatButton extends _MatButtonMixinBase // attributes, add the correct corresponding class. for (const attr of BUTTON_HOST_ATTRIBUTES) { if (this._hasHostAttributes(attr)) { - (elementRef.nativeElement as HTMLElement).classList.add(attr); + (this._getHostElement() as HTMLElement).classList.add(attr); } }