restructuring + tidying

This commit is contained in:
tsmethurst
2021-04-27 18:50:02 +02:00
parent 0967574d4d
commit f5dde82363
72 changed files with 299 additions and 370 deletions

View File

@ -26,9 +26,9 @@ import (
"github.com/superseriousbusiness/gotosocial/internal/apimodule"
"github.com/superseriousbusiness/gotosocial/internal/db"
"github.com/superseriousbusiness/gotosocial/internal/db/gtsmodel"
"github.com/superseriousbusiness/gotosocial/internal/mastotypes"
"github.com/superseriousbusiness/gotosocial/internal/oauth"
"github.com/superseriousbusiness/gotosocial/internal/router"
"github.com/superseriousbusiness/gotosocial/internal/typeutils"
)
// BasePath is the base path for this api module
@ -36,19 +36,19 @@ const BasePath = "/api/v1/apps"
// Module implements the ClientAPIModule interface for requests relating to registering/removing applications
type Module struct {
server oauth.Server
db db.DB
mastoConverter mastotypes.Converter
log *logrus.Logger
server oauth.Server
db db.DB
tc typeutils.TypeConverter
log *logrus.Logger
}
// New returns a new auth module
func New(srv oauth.Server, db db.DB, mastoConverter mastotypes.Converter, log *logrus.Logger) apimodule.ClientAPIModule {
func New(srv oauth.Server, db db.DB, tc typeutils.TypeConverter, log *logrus.Logger) apimodule.ClientAPIModule {
return &Module{
server: srv,
db: db,
mastoConverter: mastoConverter,
log: log,
server: srv,
db: db,
tc: tc,
log: log,
}
}