mirror of
https://github.com/Eggbertx/gochan.git
synced 2025-08-28 12:16:22 -07:00
Fix edit post not letting non-privileged users edit their posts
This commit is contained in:
parent
0ec36c2840
commit
46db3e0abc
3 changed files with 10 additions and 6 deletions
|
@ -12,18 +12,20 @@ const idRe = /^((reply)|(op))(\d+)/;
|
|||
|
||||
function editPost(id, _board) {
|
||||
let cookiePass = getCookie("password");
|
||||
promptLightbox(cookiePass, true, () => {
|
||||
promptLightbox(cookiePass, true, (_jq, inputData) => {
|
||||
$("input[type=checkbox]").prop("checked", false);
|
||||
$(`input#check${id}`).prop("checked", true);
|
||||
$("input#delete-password").val(inputData);
|
||||
$("input[name=edit_btn]").trigger("click");
|
||||
}, "Edit post");
|
||||
}
|
||||
|
||||
function moveThread(id, _board) {
|
||||
let cookiePass = getCookie("password");
|
||||
promptLightbox(cookiePass, true, () => {
|
||||
promptLightbox(cookiePass, true, (_jq, inputData) => {
|
||||
$("input[type=checkbox]").prop("checked", false);
|
||||
$(`input#check${id}`).prop("checked", true);
|
||||
$("input#delete-password").val(inputData);
|
||||
$("input[name=move_btn]").trigger("click");
|
||||
}, "Move thread");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue