Changed timer to return an average