package transactionimp

import (
	"github.com/tech/sendico/pkg/db/transaction"
	"go.mongodb.org/mongo-driver/v2/mongo"
)

type MongoTransactionFactory struct {
	client *mongo.Client
}

func (mtf *MongoTransactionFactory) CreateTransaction() transaction.Transaction {
	return Create(mtf.client)
}

func CreateFactory(client *mongo.Client) transaction.Factory {
	return &MongoTransactionFactory{client: client}
}
