Typescript Get First Element Of Nullable String