Skip to content

Commit

Permalink
Merge pull request #33 from dbellettini/replace-closure-with-callable
Browse files Browse the repository at this point in the history
`\Closure` is too strict as type hint
  • Loading branch information
Kevinrob committed Sep 26, 2015
2 parents 3f6e751 + ad459bc commit b793c93
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/CacheMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,11 @@ public function purgeReValidation()
}

/**
* @param \Closure $handler
* @param callable $handler
*
* @return \Closure
* @return callable
*/
public function __invoke(\Closure $handler)
public function __invoke(callable $handler)
{
return function (RequestInterface $request, array $options) use (&$handler) {
if (!isset($this->httpMethods[strtoupper($request->getMethod())])) {
Expand Down

0 comments on commit b793c93

Please sign in to comment.