qty_loader() refactoring