結果 : javascript make function call synchronous