Skip to content

Commit 78ef125

Browse files
author
Ales Rechtorik
committed
replace replace with parseFloat
1 parent 86ffa33 commit 78ef125

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib/input/input.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ export class MdAutosize implements OnInit {
168168
// if line height is explicitly set(to a pixel value), use that
169169
if (computedStyles.lineHeight && computedStyles.lineHeight.toLowerCase().indexOf('px') >= 0) {
170170
// return stripped of the "px" and as a number
171-
return +computedStyles.lineHeight.replace('px', '');
171+
return parseFloat(computedStyles.lineHeight);
172172
}
173173

174174
// create temporary element

0 commit comments

Comments
 (0)