Made offline detection compatible with IE/Safari
Used better export style