added functionality to inventory