From 61a62b27ce14a3a775eaefc9c29ce36dff1e911e Mon Sep 17 00:00:00 2001 From: webchick Date: Mon, 23 Dec 2013 13:08:08 -0800 Subject: [PATCH] Issue #2160555 by Wim Leers: Disable Edit on admin pages. --- core/modules/edit/edit.module | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/core/modules/edit/edit.module b/core/modules/edit/edit.module index bc7b314c1800..f425a69d2329 100644 --- a/core/modules/edit/edit.module +++ b/core/modules/edit/edit.module @@ -36,6 +36,12 @@ function edit_page_build(&$page) { return; } + // In-place editing is only supported on the front-end. + $path = \Drupal::request()->attributes->get('_system_path'); + if (path_is_admin($path)) { + return; + } + $page['#attached']['library'][] = array('edit', 'edit'); }