Fixing IE8 bug.

Fixes #329.