Updated timed decorator to return result of function.