/// <inheritdoc/>
        public async Task <long> RemoveAsync(long key, CancellationToken cancellationToken)
        {
            _logger.LogInformation("Removing the weight transaction ({@Id})", key);

            var transaction = await _context.WeightTransactions
                              .FindAsync(new object[] { key }, cancellationToken)
                              .ConfigureAwait(false);

            if (transaction == null)
            {
                throw new EntityNotFoundException <WeightTransaction>(key);
            }

            _context.Remove(transaction);
            await _context.SaveChangesAsync(cancellationToken).ConfigureAwait(false);

            return(key);
        }