Skip to content

Commit bdf34bf

Browse files
committed
Merge pull request BonsaiDen#196 from sweaf/master
fixed thrown TypeErrors on mac, while scrolling over the top edge
2 parents 04e401f + c67cc4e commit bdf34bf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

site/javascript/garden.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ Sections.prototype = {
3333
articleID = this.names[this.names.length - 1].id;
3434

3535
for(var i = 0, l = this.names.length; i < l; i++) {
36-
if (this.names[i].offset > scroll) {
36+
if (scroll > 0 && this.names[i].offset > scroll) {
3737
articleID = this.names[i - 1].id;
3838
break;
3939
}

0 commit comments

Comments
 (0)