Add new management methods to ReactionCounter and ReactionTotal interfaces #162
Unanswered
antonkomarev
asked this question in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
To rebuild
count
andweight
attributes onCog\Contracts\Love\Reactant\ReactionTotal\Models\ReactionTotal
andCog\Laravel\Love\Reactant\ReactionCounter\Models\ReactionCounter
classes we are dispatchingCog\Laravel\Love\Reactant\Jobs\RebuildReactionAggregatesJob
async job class.The main problem with current implementation that it knows too much about internal
ReactionTotal
andReactionCount
concrete models implementation:We need to specify
@var
in PhpDoc becauseupdate
method is not part of the counter interface.One of the solutions to introduce new methods in interfaces, then this code will look like:
Beta Was this translation helpful? Give feedback.
All reactions