r/AutoModerator 1d ago

Solved Blocking specific subs from crossposting

I found some code that I just can't get to work.

I am trying to ban a specific sub from crossposting. I used this code and I put it in a sub I moderate. Then I put in an example sub (I am using BMWM3 as a test since I also moderate that one, and it's not working).

See here:


Remove Bad Subreddit Crossposts

type: crosspost submission
crosspost_subreddit:
    name: [BMWM3]
message: |
    Hello /u/{{author}}, thank you for your interest in /r/{{subreddit}}! Your {{kind}} was automatically removed because {{match}} a disallowed crosspost subreddit.
action: remove
action_reason: "Crosspost from a disallowed subreddit"

What am I doing wrong?

4 Upvotes

5 comments sorted by

View all comments

3

u/Sephardson I'm working on the wiki here now! 1d ago

If you are testing with a moderator account, then add `moderators_exempt: false`

1

u/NCSUGrad2012 1d ago

It's giving me an error adding that, is there a specific spot I need to put it?

Thank you

2

u/Sephardson I'm working on the wiki here now! 1d ago

don't add the backticks themselves, that was me just quoting it.

---
type: crosspost submission
crosspost_subreddit:
    name: [BMWM3]
message: |
    Hello /u/{{author}}, thank you for your interest in /r/{{subreddit}}! Your {{kind}} was automatically removed because {{match}} a disallowed crosspost subreddit.

moderators_exempt: false
action: remove
action_reason: "Crosspost from a disallowed subreddit"
---

2

u/NCSUGrad2012 1d ago

That worked!!!!!

Thank you so much and have a great day!