Running editSettings() resets the discoverability settings
See original GitHub issueWhen I run the following function to update the description of my subreddit, I notice that my discoverability options re-add me to /r/all.
public async updateSidebarContent(updatedContent: string): Promise<void> {
return this.r(this.subreddit).getSettings().then(settings => {
this.r(this.subreddit).editSettings({
...settings,
description: updatedContent
})
})
}
After checking the output of getSettings(...)
I noticed that the only thing other than the description is a property called default_set
, which seems to be tied to this discoverability option.
I considered adding this as a PR, but after checking the Reddit API docs this property doesn’t seem to be listed, although it IS listed as a property in a comment on getSettings()
in Subreddit.js
, so I thought I’d double-check here first if anyone knew about this property, if this property is actually the culprit, or whether there is a reason it’s not included in the SubredditSettings
type before sending a PR your way.
Issue Analytics
- State:
- Created 3 years ago
- Comments:10 (5 by maintainers)
Top GitHub Comments
That makes sense. I was a bit worried about adding some in, as they don’t seen to be referenced in the official Reddit API documentation, but I’ll probably work on getting a more complete interface pushed up at some time this weekend.
Since we’ve only done bugfixes and no features, I’ll release a patch version this weekend if everything passes