Fixed line breaks issue and incorrent count of total