aboutsummaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-03-17 00:24:04 +0000
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-03-17 00:24:04 +0000
commitfb143a5701f15a8e9792c25ec7c0a030786896d6 (patch)
treef014b07dad8e23d07959e2a25b1f19612d581d00 /engine
parent3d3ecfa207a47198fca5658bb6aa6e27cb0f13da (diff)
downloadelgg-fb143a5701f15a8e9792c25ec7c0a030786896d6.tar.gz
elgg-fb143a5701f15a8e9792c25ec7c0a030786896d6.tar.bz2
Fixes #2242. Can now delete admin notices manually.
git-svn-id: http://code.elgg.org/elgg/trunk@8737 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine')
-rw-r--r--engine/lib/admin.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/engine/lib/admin.php b/engine/lib/admin.php
index 8ef01e7cc..efb1a4581 100644
--- a/engine/lib/admin.php
+++ b/engine/lib/admin.php
@@ -25,6 +25,9 @@
*/
function elgg_add_admin_notice($id, $message) {
if ($id && $message) {
+ if (elgg_admin_notice_exists($id)) {
+ return false;
+ }
$admin_notice = new ElggObject();
$admin_notice->subtype = 'admin_notice';
// admins can see ACCESS_PRIVATE but no one else can.
@@ -173,6 +176,8 @@ function admin_init() {
elgg_register_action('admin/menu/save', '', 'admin');
+ elgg_register_action('admin/delete_admin_notice', '', 'admin');
+
elgg_register_action('admin/plugins/simple_update_states', '', 'admin');
elgg_register_action('profile/fields/reset', '', 'admin');