Corrected bug in update functionality...