added updateClock