fixed an error showing up when trying to renote a note in the 'home' visibility setting #56

Closed
emilis wants to merge 1 commit from emilis/FoundKey:fix/renoting-home-scope into main

View file

@ -206,8 +206,8 @@ export default define(meta, paramDef, async (ps, user) => {
throw new ApiError(meta.errors.cannotReRenote);
}
// check that the visibility is not less restrictive
if (noteVisibilities.indexOf(renote.visibility) > noteVisibilities.indexOf(ps.visibility)) {
// do not allow renoting followers only/specified scope notes
if (noteVisibilities.indexOf(renote.visibility) > noteVisibilities.indexOf('home')) {
throw new ApiError(meta.errors.lessRestrictiveVisibility);
}