safari browser -1001 undefined