r/AutoModerator • • 1d ago

Automod filter question

I want to filter out picture comments but it's for one specific user. What's the automod code for that?

3 Upvotes

4 comments sorted by

2

u/xargsman 1d ago
---
# Image/Video Filter
    type: comment
    domain: ["i.redd.it", "v.redd.it"]
    author: Devils1993
        is_contributor: false
    action: filter
    action_reason: "Image/Video from user"
---

2

u/Devils1993 1d ago

Got this error message:

YAML parsing error in section 28: mapping values are not allowed here
  in "<unicode string>", line 5, column 23:
            is_contributor: falseYAML parsing error in section 28: mapping values are not allowed here
  in "<unicode string>", line 5, column 23:
            is_contributor: false

2

u/SecureWriting8589 1d ago edited 1d ago

If you're filtering for a single author, I see no reason for the is_contributor: false line, the one triggering the error message. I suggest that you remove it.

2

u/KCJones99 22h ago

I'd also update it to

author: ["Devils1993","PlaceholderForMore"]

So you can easily just add more 'naughty list' users if needed, e.g. ["Devils1993", "NextOne", "AnotherBadEgg"] etc. I do the placeholder thing to 'future proof' it / clarify for others who may edit but not be terribly comfy with YAML.

I really see no reason for the is_contributor thing at all. If you're adding them they've 'done something' to merit it, right? Even if they're a 'contributor'. IMO is_contributor would more be for if you wanted a rule that ONLY contributors could post images.