removed time-left from the couter function, and switched its call from update to transact