結果 : how to exit from if condition in javascript