Recfactoring of the html item service