Add new setting to disable posting of notification messages to file rooms.
[citadel.git] / citadel / modules / ctdlproto / serv_file.c
index 50661c7c75d64187e97edcdbef00a4d88fcc4bce..8a3bd5c823e84c89afd0d14ec6c204dab0e915ce 100644 (file)
@@ -557,14 +557,16 @@ void cmd_ucls(char *cmd)
                        fclose(fp);
                }
 
-               /* put together an upload notice */
-               snprintf(upload_notice, sizeof upload_notice,
-                       "NEW UPLOAD: '%s'\n %s\n%s\n",
-                        CC->upl_file, 
-                        CC->upl_comment, 
-                        CC->upl_mimetype);
-               quickie_message(CC->curr_user, NULL, NULL, CC->room.QRname,
-                               upload_notice, 0, NULL);
+               if ((CC->room.QRflags2 & QR2_NOUPLMSG) == 0) {
+                       /* put together an upload notice */
+                       snprintf(upload_notice, sizeof upload_notice,
+                                "NEW UPLOAD: '%s'\n %s\n%s\n",
+                                CC->upl_file, 
+                                CC->upl_comment, 
+                                CC->upl_mimetype);
+                       quickie_message(CC->curr_user, NULL, NULL, CC->room.QRname,
+                                       upload_notice, 0, NULL);
+               }
        } else {
                abort_upl(CC);
                cprintf("%d File '%s' aborted.\n", CIT_OK, CC->upl_path);