Fossil SCM

Allow disapproving Forum posts that are pending moderation, even if the post is not well-formed.

drh 2026-05-26 14:37 UTC forum-statuses
Commit 54ae84e1585cebab3e595b2fe121463f518c9e828ed5d88089c6b5fbc7e51901
1 file changed +3 -1
+3 -1
--- src/forum.c
+++ src/forum.c
@@ -2094,11 +2094,13 @@
20942094
fpid = symbolic_name_to_rid(zFpid, "f");
20952095
if( fpid<=0 || (pPost = manifest_get(fpid, CFTYPE_FORUM, 0))==0 ){
20962096
webpage_error("Missing or invalid fpid query parameter");
20972097
}
20982098
froot = db_int(0, "SELECT froot FROM forumpost WHERE fpid=%d", fpid);
2099
- if( froot==0 || (pRootPost = manifest_get(froot, CFTYPE_FORUM, 0))==0 ){
2099
+ if( (froot==0 || (pRootPost = manifest_get(froot, CFTYPE_FORUM, 0))==0)
2100
+ && P("reject")==0
2101
+ ){
21002102
webpage_error("fpid does not appear to be a forum post: \"%d\"", fpid);
21012103
}
21022104
if( P("cancel") ){
21032105
cgi_redirectf("%R/forumpost/%S",zFpid);
21042106
return;
21052107
--- src/forum.c
+++ src/forum.c
@@ -2094,11 +2094,13 @@
2094 fpid = symbolic_name_to_rid(zFpid, "f");
2095 if( fpid<=0 || (pPost = manifest_get(fpid, CFTYPE_FORUM, 0))==0 ){
2096 webpage_error("Missing or invalid fpid query parameter");
2097 }
2098 froot = db_int(0, "SELECT froot FROM forumpost WHERE fpid=%d", fpid);
2099 if( froot==0 || (pRootPost = manifest_get(froot, CFTYPE_FORUM, 0))==0 ){
 
 
2100 webpage_error("fpid does not appear to be a forum post: \"%d\"", fpid);
2101 }
2102 if( P("cancel") ){
2103 cgi_redirectf("%R/forumpost/%S",zFpid);
2104 return;
2105
--- src/forum.c
+++ src/forum.c
@@ -2094,11 +2094,13 @@
2094 fpid = symbolic_name_to_rid(zFpid, "f");
2095 if( fpid<=0 || (pPost = manifest_get(fpid, CFTYPE_FORUM, 0))==0 ){
2096 webpage_error("Missing or invalid fpid query parameter");
2097 }
2098 froot = db_int(0, "SELECT froot FROM forumpost WHERE fpid=%d", fpid);
2099 if( (froot==0 || (pRootPost = manifest_get(froot, CFTYPE_FORUM, 0))==0)
2100 && P("reject")==0
2101 ){
2102 webpage_error("fpid does not appear to be a forum post: \"%d\"", fpid);
2103 }
2104 if( P("cancel") ){
2105 cgi_redirectf("%R/forumpost/%S",zFpid);
2106 return;
2107

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button