[feature] add support for polls + receiving federated status edits (#2330)

This commit is contained in:
kim
2023-11-08 14:32:17 +00:00
committed by GitHub
parent 7204ccedc3
commit e9e5dc5a40
84 changed files with 3992 additions and 570 deletions

View File

@ -21,6 +21,7 @@ import (
"github.com/superseriousbusiness/gotosocial/internal/federation"
"github.com/superseriousbusiness/gotosocial/internal/gtsmodel"
"github.com/superseriousbusiness/gotosocial/internal/processing/common"
"github.com/superseriousbusiness/gotosocial/internal/processing/polls"
"github.com/superseriousbusiness/gotosocial/internal/state"
"github.com/superseriousbusiness/gotosocial/internal/text"
"github.com/superseriousbusiness/gotosocial/internal/typeutils"
@ -28,7 +29,7 @@ import (
)
type Processor struct {
// common processor logic
// embedded common logic
c *common.Processor
state *state.State
@ -37,12 +38,16 @@ type Processor struct {
filter *visibility.Filter
formatter *text.Formatter
parseMention gtsmodel.ParseMentionFunc
// other processors
polls *polls.Processor
}
// New returns a new status processor.
func New(
common *common.Processor,
state *state.State,
common *common.Processor,
polls *polls.Processor,
federator *federation.Federator,
converter *typeutils.Converter,
filter *visibility.Filter,
@ -56,5 +61,6 @@ func New(
filter: filter,
formatter: text.NewFormatter(state.DB),
parseMention: parseMention,
polls: polls,
}
}