Fossil SCM

Always allow the administrator to moderate attachments.

drh 2013-09-18 12:56 trunk
Commit 41d9de6e14bd37760067b86761abbe69eabe70f3
1 file changed +3 -1
+3 -1
--- src/attach.c
+++ src/attach.c
@@ -445,11 +445,13 @@
445445
@ <p>Confirm you want to delete the attachment shown below.
446446
@ <input type="submit" name="confirm" value="Confirm">
447447
@ </form>
448448
}
449449
450
- isModerator = (zTktUuid && g.perm.ModTkt) || (zWikiName && g.perm.ModWiki);
450
+ isModerator = g.perm.Admin ||
451
+ (zTktUuid && g.perm.ModTkt) ||
452
+ (zWikiName && g.perm.ModWiki);
451453
if( isModerator && (zModAction = P("modaction"))!=0 ){
452454
if( strcmp(zModAction,"delete")==0 ){
453455
moderation_disapprove(rid);
454456
if( zTktUuid ){
455457
cgi_redirectf("%R/tktview/%s", zTktUuid);
456458
--- src/attach.c
+++ src/attach.c
@@ -445,11 +445,13 @@
445 @ <p>Confirm you want to delete the attachment shown below.
446 @ <input type="submit" name="confirm" value="Confirm">
447 @ </form>
448 }
449
450 isModerator = (zTktUuid && g.perm.ModTkt) || (zWikiName && g.perm.ModWiki);
 
 
451 if( isModerator && (zModAction = P("modaction"))!=0 ){
452 if( strcmp(zModAction,"delete")==0 ){
453 moderation_disapprove(rid);
454 if( zTktUuid ){
455 cgi_redirectf("%R/tktview/%s", zTktUuid);
456
--- src/attach.c
+++ src/attach.c
@@ -445,11 +445,13 @@
445 @ <p>Confirm you want to delete the attachment shown below.
446 @ <input type="submit" name="confirm" value="Confirm">
447 @ </form>
448 }
449
450 isModerator = g.perm.Admin ||
451 (zTktUuid && g.perm.ModTkt) ||
452 (zWikiName && g.perm.ModWiki);
453 if( isModerator && (zModAction = P("modaction"))!=0 ){
454 if( strcmp(zModAction,"delete")==0 ){
455 moderation_disapprove(rid);
456 if( zTktUuid ){
457 cgi_redirectf("%R/tktview/%s", zTktUuid);
458

Keyboard Shortcuts

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