refactoring promise item edit create