not-an-aardvark / snoowrap

A JavaScript wrapper for the reddit API
MIT License
1.01k stars 125 forks source link

removal_reason null for moderator-removed comments #359

Open OminousAnemone opened 2 years ago

OminousAnemone commented 2 years ago

Comments removed by moderators are not logged with any removal_reason. They appear to have removal_reason: null

iMrDJAi commented 2 years ago

@OminousAnemone Thank you for pointing this out! ReplyableContent#remove only accept options object with one property (spam), others are not supported yet since the library haven't been updated in a while.

OminousAnemone commented 2 years ago

Thank you for the response! Any workaround here that you know of to identify removed comments?

Also curious if you think the library will be updated/supported going forward. I'm new to snoowrap but it's been very useful so far.

iMrDJAi commented 2 years ago

@OminousAnemone I checked the official Reddit API docs and I found no reference to removal_reason, but as far as I know, the docs page is outdated.

However, PRAW supports it, you can try the mod_note property:

await r._post({uri: 'api/remove', form: {mod_note: 'some text here', id: commentId}})

Also curious if you think the library will be updated/supported going forward.

It will be updated after finishing the TypeScript migration. Also, some missing API features should be added before the upcoming 2.0 release. It may take a while...