adding wrapper function to time functions