mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-10-30 15:32:25 -05:00
[chore] Deinterface processor and subprocessors (#1501)
* [chore] Deinterface processor and subprocessors * expose subprocessors via function calls * missing license header
This commit is contained in:
parent
adb596600b
commit
b6fbdc66c1
246 changed files with 2545 additions and 4549 deletions
|
|
@ -33,7 +33,8 @@ import (
|
|||
"github.com/superseriousbusiness/gotosocial/internal/uris"
|
||||
)
|
||||
|
||||
func (p *processor) Create(ctx context.Context, account *gtsmodel.Account, form *apimodel.ReportCreateRequest) (*apimodel.Report, gtserror.WithCode) {
|
||||
// Create creates one user report / flag, using the provided form parameters.
|
||||
func (p *Processor) Create(ctx context.Context, account *gtsmodel.Account, form *apimodel.ReportCreateRequest) (*apimodel.Report, gtserror.WithCode) {
|
||||
if account.ID == form.AccountID {
|
||||
err := errors.New("cannot report your own account")
|
||||
return nil, gtserror.NewErrorBadRequest(err, err.Error())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue