func (r *Repo) updateSyncTime(ctx context.Context) error {
	rev, _, err := r.lastSyncTime(ctx)
	if err != nil && kivik.StatusCode(err) != kivik.StatusNotFound {
		return err
	}

	u, err := r.CurrentUser()
	if err != nil {
		return err
	}
	db, err := r.local.DB(ctx, "user-"+u)
	if err != nil {
		return err
	}
	doc := lastSyncTimestampDoc{
		ID:       lastSyncTimestampDocID,
		Rev:      rev,
		LastSync: now(),
	}
	_, err = db.Put(ctx, lastSyncTimestampDocID, doc)
	return err
}
// updateSyncTime updates the local timestamp for the last sync.
updateSyncTime updates the local timestamp for the last sync.
// updateSyncTime updates the local timestamp for the last sync .
func (r *Repo) updateSyncTime(ctx context.Context) error {
	rev, _, err := r.lastSyncTime(ctx)
	if err != nil && kivik.StatusCode(err) != kivik.StatusNotFound {
		return err
	}
	u, err := r.CurrentUser()
	if err != nil {
		return err
	}
	db, err := r.local.DB(ctx, "user-"+u)
	if err != nil {
		return err
	}
	doc := lastSyncTimestampDoc{
		ID:       lastSyncTimestampDocID,
		Rev:      rev,
		LastSync: now(),
	}
	_, err = db.Put(ctx, lastSyncTimestampDocID, doc)
	return err
}
func ( r * Repo ) updateSyncTime ( ctx context . Context ) error { rev , _ , err := r . lastSyncTime ( ctx ) if err != nil && kivik . StatusCode ( err ) != kivik . StatusNotFound { return err } u , err := r . CurrentUser ( ) if err != nil { return err } db , err := r . local . DB ( ctx , " " + u ) if err != nil { return err } doc := lastSyncTimestampDoc { ID : lastSyncTimestampDocID , Rev : rev , LastSync : now ( ) , } _ , err = db . Put ( ctx , lastSyncTimestampDocID , doc ) return err }
updateSyncTime updates the local timestamp for the last sync.
updateSyncTime updates the local timestamp for the last sync .