import type { SelectQueryBuilder, ObjectLiteral, DataSource } from 'typeorm';

export function withPessimisticWriteLock<T extends ObjectLiteral>(
  qb: SelectQueryBuilder<T>,
  _dataSource: DataSource,
): SelectQueryBuilder<T> {
  return qb.setLock('pessimistic_write');
}
