Refactor and extend supermarket