]> code.citadel.org Git - citadel.git/blobdiff - citadel/serv_notes.c
mk_module_init.sh now tests to see if echo supports -e and -E
[citadel.git] / citadel / serv_notes.c
index 322550df5be6aa076eee6b9245f74fda63563323..47e968b03bd22cfc8ba6b00947e2edda66a9742a 100644 (file)
 #include <limits.h>
 #include "citadel.h"
 #include "server.h"
-#include "sysdep_decls.h"
 #include "citserver.h"
 #include "support.h"
 #include "config.h"
-#include "serv_extensions.h"
 #include "room_ops.h"
 #include "user_ops.h"
 #include "policy.h"
 #include "msgbase.h"
 #include "tools.h"
 
+#include "ctdl_module.h"
+
+
 
 /*
  * If we are in a "notes" view room, and the client has sent an RFC822
  * message containing an X-KOrg-Note-Id: field (Aethera does this, as
- * do some Kolab clients) then set both the Subject and the Extended ID
+ * do some Kolab clients) then set both the Subject and the Exclusive ID
  * of the message to that.  It's going to be a UUID so we want to replace
  * any existing message containing that UUID.
  */
@@ -59,7 +60,7 @@ int serv_notes_beforesave(struct CtdlMessage *msg)
 
        /* First determine if this room has the "notes" view set */
 
-       if (CC->curr_view != VIEW_NOTES) {
+       if (CC->room.QRdefaultview != VIEW_NOTES) {
                return(0);                      /* not notes; do nothing */
        }
 
@@ -102,8 +103,10 @@ int serv_notes_beforesave(struct CtdlMessage *msg)
 }
 
 
-char *serv_notes_init(void)
+CTDL_MODULE_INIT(notes)
 {
        CtdlRegisterMessageHook(serv_notes_beforesave, EVT_BEFORESAVE);
+
+       /* return our Subversion id for the Log */
        return "$Id$";
 }