ThomasArdal / gInfinity

gInfinity extends your favorite search engine Google with infinite scroll. Scroll down to the bottom of the search result and the following 20 search results are automatically added to the search result.
10 stars 9 forks source link

Fixes the extension's behavior that chrome returns maxLength -1 if it… #3

Closed benelot closed 8 years ago

benelot commented 8 years ago

… is not set.. Fixes #1.

Fixes the extension's behavior that chrome returns maxLength -1 if it is not set. So we check if event.target.maxLength > 0. event.target.maxLength is a number and not a complex element, so the if(event.target.maxLength) works directly on the number.

benelot commented 8 years ago

Here is the other proposed fix in case you want it.

ThomasArdal commented 8 years ago

@benelot Updated in store. Thanks.