Guest User

Untitled

a guest
Jun 18th, 2018
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. /**
  2. * Loop through the meta fields looking for things to replace
  3. * @param array $replace
  4. */
  5. protected function _metaReplacements(array $replace)
  6. {
  7. $doReplace = function(&$item, $key) use ($replace) {
  8. foreach($replace AS $needle => $replace) {
  9. $item = preg_replace('/'. $needle .'/', $replace, $item);
  10. }
  11. };
  12. array_walk_recursive($this->_restResponse['head'], $doReplace);
  13. }
Add Comment
Please, Sign In to add comment