src/Update/Updater.php
public function removeComposerPatch($package, $url) {
    $composer_json = $this->getComposerJson();
    if (!empty($composer_json['extra']['patches'][$package])) {
      foreach ($composer_json['extra']['patches'][$package] as $key => $patch_url) {
        if ($patch_url == $url) {
          unset($composer_json['extra']['patches'][$package][$key]);
          // If that was the only patch for this module, unset the parent too.
          if (empty($composer_json['extra']['patches'][$package])) {
            unset($composer_json['extra']['patches'][$package]);
          }
          $this->writeComposerJson($composer_json);

          return TRUE;
        }
      }
    }
    return FALSE;
  }
public function removeComposerPatch($package, $url) {
    $composer_json = $this->getComposerJson();
    if (!empty($composer_json['extra']['patches'][$package])) {
      foreach ($composer_json['extra']['patches'][$package] as $key => $patch_url) {
        if ($patch_url == $url) {
          unset($composer_json['extra']['patches'][$package][$key]);
          // If that was the only patch for this module, unset the parent too.
          if (empty($composer_json['extra']['patches'][$package])) {
            unset($composer_json['extra']['patches'][$package]);
          }
          $this->writeComposerJson($composer_json);

          return TRUE;
        }
      }
    }
    return FALSE;
  }
public function removeComposerPatch ( $ package , $ url ) { $ composer_json = $ this -> getComposerJson ( ) ; if ( ! empty ( $ composer_json [ 'extra' ] [ 'patches' ] [ $ package ] ) ) { foreach ( $ composer_json [ 'extra' ] [ 'patches' ] [ $ package ] as $ key => $ patch_url ) { if ( $ patch_url == $ url ) { unset ( $ composer_json [ 'extra' ] [ 'patches' ] [ $ package ] [ $ key ] ) ; // If that was the only patch for this module, unset the parent too. if ( empty ( $ composer_json [ 'extra' ] [ 'patches' ] [ $ package ] ) ) { unset ( $ composer_json [ 'extra' ] [ 'patches' ] [ $ package ] ) ; } $ this -> writeComposerJson ( $ composer_json ) ; return TRUE ; } } } return FALSE ; }
Removes a patch from repo's root composer.json file.

@param string $package
The composer package name, e.g., 'drupal/features'.

@param string $url
The URL of the patch.

@return bool
TRUE if patch was removed, otherwise FALSE.
Removes a patch from repo s root composer . json file .