Minor refactorings
Make refreshing an item work