toIntOrNull

Returns content as int only if content can be int, otherwise null.