Fix a bug with Safari