working on update method
resolved merge conflict