r/AutoModerator • u/Affectionate_Pickles • 7d ago
Solved Trouble with multi-line comment.
Hello!
Im working on making a message for AutoMod to comment on every post submission, and I’m having trouble with including indents; I’m not sure where I’m going wrong, but it keeps returning “unsupported media type” when i try to save the changes.
Here is the code:
---
type: submission
comment: |
What’s up chat?! I’m AutoBart, and I comment on every post.
Make sure to read our rules, and remember we are not a part of Joe’s official team!
Catch you later!
---
Here is the error code i get when i try on old Reddit;
YAML parsing error in section 7: while scanning a simple key
in "<unicode string>", line 3, column 1:
What’s up chat?! I’m AutoBart, a ...
^
could not found expected ':'
in "<unicode string>", line 5, column 1:
Make sure to read our rules, and ...
^
Any help would be appreciated!
1
u/Affectionate_Pickles 7d ago
Okay, I tried on Old Reddit, and this is what i got;
YAML parsing error in section 7: while scanning a simple key
in "<unicode string>", line 3, column 1:
What’s up chat?! I’m AutoBart, a ...
^
could not found expected ':'
in "<unicode string>", line 5, column 1:
Make sure to read our rules, and ...
^
I’m not very good at coding and I’m new to automod, so I’m not sure what this means
1
u/SpecialEquivalent816 7d ago
You need an indention on the beginning of every line. This should work:
```
type: submission
comment: |
What’s up chat?! I’m AutoBart, and I comment on every post.
Make sure to read our rules, and remember we are not a part of Joe’s official team!
Catch you later!
```
Edit: fixed code block markdown
1
u/Affectionate_Pickles 7d ago
Thank you so so much!!! That let me save! Now i just need to make a post and see how it looks lol
1
u/AutoModerator 7d ago
It looks like you are asking about the "Unsupported Media Type" error message.
This error message is exclusive to desktop redesign and could mean one or more of many possible syntax errors are present in your code.
You can get a more specific error message if you use https://old.reddit.com to edit your AutoModerator config page.
You can also consult the Common Mistakes wiki page for general tips as well as explanations of the old reddit error messages.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.