created Create and Update handlers. code clean up