Display alerts only if the message isn't empty.