Finish synchronization function