[packages/dokuwiki] notify on media uploads as well
glen
glen at pld-linux.org
Mon Jul 30 17:09:48 CEST 2012
commit 28ed6fc5b86fcfe505e44a65165728fe973106f9
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Mon Jul 30 18:08:15 2012 +0300
notify on media uploads as well
dokuwiki-mailthreads.patch | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
---
diff --git a/dokuwiki-mailthreads.patch b/dokuwiki-mailthreads.patch
index 83e89de..c3142c5 100644
--- a/dokuwiki-mailthreads.patch
+++ b/dokuwiki-mailthreads.patch
@@ -25,3 +25,25 @@ index 02ed243..befc3e1 100644
return $mail->send();
}
+--- dokuwiki/./inc/media.php~ 2012-07-30 17:32:21.000000000 +0300
++++ dokuwiki/./inc/media.php 2012-07-30 17:57:02.763464890 +0300
+@@ -561,6 +544,19 @@
+ $mail->to($to);
+ $mail->subject($lang['mail_upload'].' '.$id);
+ $mail->setBody($text,$trep);
++
++ $file = mediaFN($id);
++ $cur = @filemtime($file);
++
++ $server = parse_url(DOKU_URL, PHP_URL_HOST);
++ $listid = join('.', array_reverse(explode('/', DOKU_BASE))).$server;
++ $listid = strtolower(trim($listid, '.'));
++
++ $mail->setHeader('Message-Id', "<$id?rev=$cur@$listid>", false);
++ if ($old_rev) {
++ $mail->setHeader('In-Reply-To', "<$id?rev=$old_rev@$listid>", false);
++ }
++
+ return $mail->send();
+ }
+
More information about the pld-cvs-commit
mailing list