Skip to content

Commit

Permalink
php7.1开始 array_walk_recursive 就不消耗指针了
Browse files Browse the repository at this point in the history
  • Loading branch information
hongweipeng authored and liu21st committed Oct 23, 2019
1 parent 0b3a963 commit 778fe7e
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions src/think/Request.php
Original file line number Diff line number Diff line change
Expand Up @@ -1101,7 +1101,6 @@ public function cookie(string $name = '', $default = null, $filter = '')

if (is_array($data)) {
array_walk_recursive($data, [$this, 'filterValue'], $filter);
reset($data);
} else {
$this->filterValue($data, $name, $filter);
}
Expand Down Expand Up @@ -1288,7 +1287,6 @@ protected function filterData($data, $filter, $name, $default)

if (is_array($data)) {
array_walk_recursive($data, [$this, 'filterValue'], $filter);
reset($data);
} else {
$this->filterValue($data, $name, $filter);
}
Expand Down

0 comments on commit 778fe7e

Please sign in to comment.