Pretty sure you were meant to return an empty string and not null if text is null.