-
-
Notifications
You must be signed in to change notification settings - Fork 750
Reconsider FakeContext usage in infractions code #2571
Copy link
Copy link
Open
Labels
a: filtersRelated to message filters: (antimalware, antispam, filtering, token_remover)Related to message filters: (antimalware, antispam, filtering, token_remover)a: moderationRelated to community moderation functionality: (moderation, defcon, verification)Related to community moderation functionality: (moderation, defcon, verification)s: planningDiscussing detailsDiscussing detailst: enhancementChanges or improvements to existing featuresChanges or improvements to existing features
Metadata
Metadata
Assignees
Labels
a: filtersRelated to message filters: (antimalware, antispam, filtering, token_remover)Related to message filters: (antimalware, antispam, filtering, token_remover)a: moderationRelated to community moderation functionality: (moderation, defcon, verification)Related to community moderation functionality: (moderation, defcon, verification)s: planningDiscussing detailsDiscussing detailst: enhancementChanges or improvements to existing featuresChanges or improvements to existing features
Type
Fields
Give feedbackNo fields configured for issues without a type.
I think the issue now is that we have 3 context classes:
Context,FakeContextandFilterContextthat are being used for conversion, andpost_infractiontakes eitherContextorFakeContext.In this particular case, I think it's an instance of
FilterContextthat's being converted toFakeContextat the level of theInfractionAndNotification.actionmethod .But I do agree that it might need to be cleaned up.
I'll try to tackle this next.
Originally posted by @shtlrs in #2556 (comment)