/// <summary>
        /// Reports the end of the syncing operation
        /// </summary>
        /// <returns></returns>
        private async Task ReportEnd(System.Threading.Timer timer)
        {
            using var uow = new UnitOfWork();

            var syncOperation = await GetSyncOperation(uow);

            syncOperation.DateFinished = DateTime.UtcNow;
            syncOperation.IsRunning    = false;

            // Stop Threading timer
            timer.Change(System.Threading.Timeout.Infinite, System.Threading.Timeout.Infinite);
            await timer.DisposeAsync();

            await uow.CommitChangesAsync();

            uow.Dispose();
        }