You are here

function rest_update_8203 in Drupal 8

Enable BC for EntityResource: continue to use permissions.

File

core/modules/rest/rest.install, line 64
Install, update and uninstall functions for the rest module.

Code

function rest_update_8203() {
  $config_factory = \Drupal::configFactory();
  $rest_settings = $config_factory
    ->getEditable('rest.settings');
  $rest_settings
    ->set('bc_entity_resource_permissions', TRUE)
    ->save(TRUE);
}