Skip to content

Commit

Permalink
Rename "original" to "originalHeight" for clarity
Browse files Browse the repository at this point in the history
  • Loading branch information
njam committed Dec 9, 2014
1 parent a9af470 commit 3c6489f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions jquery.autosize.js
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@
// Using mainly bare JS in this function because it is going
// to fire very often while typing, and needs to very efficient.
function adjust() {
var height, original;
var height, originalHeight;

if (mirrored !== ta) {
initMirror();
Expand All @@ -176,7 +176,7 @@

mirror.value += options.append || '';
mirror.style.overflowY = ta.style.overflowY;
original = parseFloat(ta.style.height) || 0;
originalHeight = parseFloat(ta.style.height) || 0;

// Setting scrollTop to zero is needed in IE8 and lower for the next step to be accurately applied
mirror.scrollTop = 0;
Expand All @@ -198,7 +198,7 @@

height += boxOffset;

if (original !== height) {
if (originalHeight !== height) {
ta.style.height = height + 'px';

// Trigger a repaint for IE8 for when ta is nested 2 or more levels inside an inline-block
Expand Down

0 comments on commit 3c6489f

Please sign in to comment.