Tracker updated into a proper function form.