diff --git a/public/app/themes/clarity/functions.php b/public/app/themes/clarity/functions.php index 6bf51e58b..969eecf0b 100644 --- a/public/app/themes/clarity/functions.php +++ b/public/app/themes/clarity/functions.php @@ -125,57 +125,3 @@ $search = new MOJ\Intranet\Search(); $search->hooks(); - -/** - * Add logging on potential causes of high CPU usage - */ - -// Log on document_serve -add_action('serve_document', function ( $post_id, $file ) { - error_log('CDPT_Debug: document_serve: ' . $post_id . ' ' . $file); -}, 10, 2); - -// Log on document_serve_done -add_action('document_serve_done', function ($file, $attach_id ) { - error_log('CDPT_Debug: document_serve_done: ' . $file . ' ' . $attach_id); -}, 10, 2); - -// Log on document edit -add_action('document_edit', function () { - error_log('CDPT_Debug: document_edit'); -}); - -// Log on document saved -add_action('document_saved', function ($doc_id, $attach_id) { - error_log('CDPT_Debug: document_saved: ' . $doc_id . ' ' . $attach_id); -}, 10, 2); - -// Log on attachment upload -add_action('add_attachment', function ($attach_id) { - error_log('CDPT_Debug: add_attachment: ' . $attach_id); -}); - -// Log on edit post -add_action('edit_post', function ($post_id) { - error_log('CDPT_Debug: edit_post: ' . $post_id); -}); - -// Log on post save -add_action('save_post', function ($post_id) { - error_log('CDPT_Debug: save_post: ' . $post_id); -}); - -// Log on S3 upload - as3cf_post_upload_attachment -add_action('as3cf_post_upload_attachment', function ($source_id, $item) { - error_log('CDPT_Debug: as3cf_post_upload_attachment: ' . $source_id); -}, 10, 2); - -// Log on as3cf_pre_upload_object -add_action('as3cf_pre_upload_object', function ($args, $file) { - error_log('CDPT_Debug: as3cf_pre_upload_object'); -}, 10, 2); - -// Log on as3cf_post_upload_item -add_action('as3cf_post_upload_item', function ($item) { - error_log('CDPT_Debug: as3cf_post_upload_item'); -});