mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2026-01-03 07:13:16 -06:00
start moving to bun
This commit is contained in:
parent
071eca20ce
commit
29b4adfb69
175 changed files with 16045 additions and 945 deletions
|
|
@ -19,6 +19,7 @@
|
|||
package admin
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
apimodel "github.com/superseriousbusiness/gotosocial/internal/api/model"
|
||||
|
|
@ -27,10 +28,10 @@ import (
|
|||
"github.com/superseriousbusiness/gotosocial/internal/gtsmodel"
|
||||
)
|
||||
|
||||
func (p *processor) DomainBlockGet(account *gtsmodel.Account, id string, export bool) (*apimodel.DomainBlock, gtserror.WithCode) {
|
||||
func (p *processor) DomainBlockGet(ctx context.Context, account *gtsmodel.Account, id string, export bool) (*apimodel.DomainBlock, gtserror.WithCode) {
|
||||
domainBlock := >smodel.DomainBlock{}
|
||||
|
||||
if err := p.db.GetByID(id, domainBlock); err != nil {
|
||||
if err := p.db.GetByID(ctx, id, domainBlock); err != nil {
|
||||
if err != db.ErrNoEntries {
|
||||
// something has gone really wrong
|
||||
return nil, gtserror.NewErrorInternalError(err)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue