mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2025-01-11 08:01:03 -07:00
update file sensitivity on note edit
This commit is contained in:
parent
e58d1d7695
commit
a56c7fe1d8
1 changed files with 6 additions and 0 deletions
|
@ -589,6 +589,12 @@ export async function updateNote(value: string | IObject, resolver?: Resolver) {
|
||||||
update.comment = altText;
|
update.comment = altText;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Don't unmark previously marked sensitive files,
|
||||||
|
// but if edited post contains sensitive marker, update it.
|
||||||
|
if (post.sensitive && !file.isSensitive) {
|
||||||
|
update.isSensitive = post.sensitive;
|
||||||
|
}
|
||||||
|
|
||||||
if (notEmpty(update)) {
|
if (notEmpty(update)) {
|
||||||
await DriveFiles.update(file.id, update);
|
await DriveFiles.update(file.id, update);
|
||||||
publishing = true;
|
publishing = true;
|
||||||
|
|
Loading…
Reference in a new issue