Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

MDL-45144 delete duplicated legacy log entries in mod_book

The general agreement is we should trigger one event
per simple action.

This partially resolves MDL-39963.
  • Loading branch information...
commit 98cb244de12262efae734dd4a38a73915bb89b55 1 parent 43a7ac7
Petr Skoda authored
View
1  mod/book/delete.php
@@ -77,7 +77,6 @@
$fs->delete_area_files($context->id, 'mod_book', 'chapter', $chapter->id);
$DB->delete_records('book_chapters', array('id'=>$chapter->id));
- add_to_log($course->id, 'course', 'update mod', '../mod/book/view.php?id='.$cm->id, 'book '.$book->id);
$params = array(
'context' => $context,
'objectid' => $chapter->id
View
2  mod/book/edit.php
@@ -75,7 +75,6 @@
$DB->update_record('book_chapters', $data);
$DB->set_field('book', 'revision', $book->revision+1, array('id'=>$book->id));
- add_to_log($course->id, 'course', 'update mod', '../mod/book/view.php?id='.$cm->id, 'book '.$book->id);
$params = array(
'context' => $context,
'objectid' => $data->id
@@ -110,7 +109,6 @@
$DB->update_record('book_chapters', $data);
$DB->set_field('book', 'revision', $book->revision+1, array('id'=>$book->id));
- add_to_log($course->id, 'course', 'update mod', '../mod/book/view.php?id='.$cm->id, 'book '.$book->id);
$params = array(
'context' => $context,
'objectid' => $data->id
View
4 mod/book/move.php
@@ -185,10 +185,6 @@
}
}
-// MDL-39963 Decide what to do with those logs.
-add_to_log($course->id, 'course', 'update mod', '../mod/book/view.php?id='.$cm->id, 'book '.$book->id);
-add_to_log($course->id, 'book', 'update', 'view.php?id='.$cm->id, $book->id, $cm->id);
-
book_preload_chapters($book); // fix structure
$DB->set_field('book', 'revision', $book->revision+1, array('id'=>$book->id));
View
4 mod/book/show.php
@@ -79,10 +79,6 @@
}
}
-// MDL-39963 Decide what to do with those logs.
-add_to_log($course->id, 'course', 'update mod', '../mod/book/view.php?id='.$cm->id, 'book '.$book->id);
-add_to_log($course->id, 'book', 'update', 'view.php?id='.$cm->id, $book->id, $cm->id);
-
book_preload_chapters($book); // fix structure
$DB->set_field('book', 'revision', $book->revision+1, array('id'=>$book->id));
View
1  mod/book/tool/importhtml/locallib.php
@@ -154,7 +154,6 @@ function toolbook_importhtml_import_chapters($package, $type, $book, $context, $
}
}
- add_to_log($book->course, 'course', 'update mod', '../mod/book/view.php?id='.$context->instanceid, 'book '.$book->id);
$fs->delete_area_files($context->id, 'mod_book', 'importhtmltemp', 0);
// update the revision flag - this takes a long time, better to refetch the current value
Please sign in to comment.
Something went wrong with that request. Please try again.