fix bug in safari extension