AbstractUIDetails: do not let getTitle return null

Since it is possible for getIdentifier() to return null, we need to
guard against that circumstance, and only return non-null identifiers.