Refactors getItems function
Refactors Store getItems