original_string: protected function remove_blacklisted_features_from_list($features, $blacklist) {
  
          // If no blacklist passed then return.
          if (empty($blacklist)) {
              return $features;
          }
  
          // If there is no feature in suite then just return what was passed.
          if (empty($features)) {
              return $features;
          }
  
          if (!is_array($blacklist)) {
              $blacklist = array($blacklist);
          }
  
          // Remove blacklisted features.
          foreach ($blacklist as $blacklistpath) {
  
              list($key, $featurepath) = $this->get_clean_feature_key_and_path($blacklistpath);
  
              if (isset($features[$key])) {
                  $features[$key] = null;
                  unset($features[$key]);
              } else {
                  $featurestocheck = $this->get_components_features();
                  if (!isset($featurestocheck[$key]) && (!defined('PHPUNIT_TEST') || !PHPUNIT_TEST)) {
                      behat_error(BEHAT_EXITCODE_REQUIREMENT, 'Blacklisted feature "' . $blacklistpath . '" not found.');
                  }
              }
          }
  
          return $features;
      }
code: protected function remove_blacklisted_features_from_list($features, $blacklist) {
  
          // If no blacklist passed then return.
          if (empty($blacklist)) {
              return $features;
          }
  
          // If there is no feature in suite then just return what was passed.
          if (empty($features)) {
              return $features;
          }
  
          if (!is_array($blacklist)) {
              $blacklist = array($blacklist);
          }
  
          // Remove blacklisted features.
          foreach ($blacklist as $blacklistpath) {
  
              list($key, $featurepath) = $this->get_clean_feature_key_and_path($blacklistpath);
  
              if (isset($features[$key])) {
                  $features[$key] = null;
                  unset($features[$key]);
              } else {
                  $featurestocheck = $this->get_components_features();
                  if (!isset($featurestocheck[$key]) && (!defined('PHPUNIT_TEST') || !PHPUNIT_TEST)) {
                      behat_error(BEHAT_EXITCODE_REQUIREMENT, 'Blacklisted feature "' . $blacklistpath . '" not found.');
                  }
              }
          }
  
          return $features;
      }
code_tokens: protected function remove_blacklisted_features_from_list ( $ features , $ blacklist ) { // If no blacklist passed then return. if ( empty ( $ blacklist ) ) { return $ features ; } // If there is no feature in suite then just return what was passed. if ( empty ( $ features ) ) { return $ features ; } if ( ! is_array ( $ blacklist ) ) { $ blacklist = array ( $ blacklist ) ; } // Remove blacklisted features. foreach ( $ blacklist as $ blacklistpath ) { list ( $ key , $ featurepath ) = $ this -> get_clean_feature_key_and_path ( $ blacklistpath ) ; if ( isset ( $ features [ $ key ] ) ) { $ features [ $ key ] = null ; unset ( $ features [ $ key ] ) ; } else { $ featurestocheck = $ this -> get_components_features ( ) ; if ( ! isset ( $ featurestocheck [ $ key ] ) && ( ! defined ( 'PHPUNIT_TEST' ) || ! PHPUNIT_TEST ) ) { behat_error ( BEHAT_EXITCODE_REQUIREMENT , 'Blacklisted feature "' . $ blacklistpath . '" not found.' ) ; } } } return $ features ; }
docstring: Remove list of blacklisted features from the feature list.
  
  @param array $features list of original features.
  @param array|string $blacklist list of features which needs to be removed.
  @return array features - blacklisted features.
docstring_tokens: Remove list of blacklisted features from the feature list .