Use appendIf(..) method of MessageStringCollector where it is relevant