SingleOrNull<T> extension

on

Methods

singleOrNull([bool test(T)?]) → T?
Returns the single element of a length = 1 list or null otherwise.