update activities duration