fix cross origin bug