結果 : typescript call function if not undefined