Fixed compatibility issue with firefox