Facebook
From Scribby Motmot, 5 Years ago, written in Plain Text.
This paste is a reply to Untitled from Gentle Peccary - go back
Embed
Viewing differences between Untitled and Re: Untitled
func (s *Service) DoSomething(name string) error {

    
{
    return 
s.d.Transaction(func(tx transaction(func(tx Interface) error {

    })

})
}

func (s *Service) transaction(fn func(tx Interface) error) error {
    return s.d.Transaction(func(tx *db.ClusterTx) error {
        return fn(tx)
    })
}