summaryrefslogtreecommitdiff
path: root/inc/changelog.php
diff options
context:
space:
mode:
Diffstat (limited to 'inc/changelog.php')
-rw-r--r--inc/changelog.php14
1 files changed, 13 insertions, 1 deletions
diff --git a/inc/changelog.php b/inc/changelog.php
index bb00df76c..15cd46d77 100644
--- a/inc/changelog.php
+++ b/inc/changelog.php
@@ -37,6 +37,15 @@ function parseChangelogLine($line) {
/**
* Add's an entry to the changelog and saves the metadata for the page
*
+ * @param int $date Timestamp of the change
+ * @param String $id Name of the affected page
+ * @param String $type Type of the change see DOKU_CHANGE_TYPE_*
+ * @param String $summary Summary of the change
+ * @param mixed $extra In case of a revert the revision (timestmp) of the reverted page
+ * @param array $flags Additional flags in a key value array.
+ * Availible flags:
+ * - ExternalEdit - mark as an external edit.
+ *
* @author Andreas Gohr <andi@splitbrain.org>
* @author Esther Brunner <wikidesign@gmail.com>
* @author Ben Coburn <btcoburn@silicodon.net>
@@ -75,7 +84,10 @@ function addLogEntry($date, $id, $type=DOKU_CHANGE_TYPE_EDIT, $summary='', $extr
$meta = array();
if (!$INFO['exists'] && empty($oldmeta['persistent']['date']['created'])){ // newly created
$meta['date']['created'] = $created;
- if ($user) $meta['creator'] = $INFO['userinfo']['name'];
+ if ($user){
+ $meta['creator'] = $INFO['userinfo']['name'];
+ $meta['user'] = $user;
+ }
} elseif (!$INFO['exists'] && !empty($oldmeta['persistent']['date']['created'])) { // re-created / restored
$meta['date']['created'] = $oldmeta['persistent']['date']['created'];
$meta['date']['modified'] = $created; // use the files ctime here