You probably also want to wrap the 'before' and 'after' functions.