結果 : typescript determine object type