Issue #2160555 by Wim Leers: Disable Edit on admin pages.

8.0.x
webchick 2013-12-23 13:08:08 -08:00
parent cef84c1877
commit 61a62b27ce
1 changed files with 6 additions and 0 deletions

View File

@ -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');
}