Skip to content

Commit

Permalink
client/upload: send state of image's anonymous checkbox as boolean
Browse files Browse the repository at this point in the history
Anonymous checkbox on images would not actually do anything, when the
global checkbox was unchecked. The value of anonymous becomes a node,
and it fails the anonymous === true check in save().
I don't understand why anonymous is treated differently from other
post parameters and supplied as an argument to save().
Keeping it the way it is, I guess...
  • Loading branch information
po5 authored and neobooru committed Jun 26, 2023
1 parent 9ae7292 commit 71c4f0e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client/js/views/post_upload_view.js
Original file line number Diff line number Diff line change
Expand Up @@ -322,8 +322,8 @@ class PostUploadView extends events.EventTarget {
}

let anonymous = this._uploadAllAnonymous.checked;
if (!anonymous) {
anonymous = rowNode.querySelector(".anonymous input:checked");
if (!anonymous && rowNode.querySelector(".anonymous input:checked")) {
anonymous = true;
}
uploadable.anonymous = anonymous;

Expand Down

0 comments on commit 71c4f0e

Please sign in to comment.