Restore IE8 compatibility

The previous construction made IE8 to throw some errors.