update logic implemented