結果 : javascript wait before executing function