In memcache_admin_init() we register a shutdown handler and add memcache_admin/memcache.js. These are only used when $conf['show_memcache_statistics'] is TRUE, but they are always added.

This patch moved the access control further up, so the .js isn't added and the shutdown handles isn't registered, unless it is needed.

I have removed "function_exists('user_access')". memcache_admin_init() is invoked at the end of _drupal_bootstrap_full() after the call to module_invoke_all(), i.e. user.module has already been loaded.

CommentFileSizeAuthor
memcache_admin_init.patch2.25 KBc960657

Comments

markpavlitski’s picture

Status: Needs review » Closed (duplicate)