mirror of
https://github.com/Yetangitu/ampache
synced 2025-10-05 10:49:37 +02:00
Move from React 0.4.0 to 0.3.4 for PHP 5.3 compatibility reasons
This commit is contained in:
parent
d3f01a3bc7
commit
7f82bea13e
50 changed files with 608 additions and 1937 deletions
|
@ -4,6 +4,7 @@ namespace React\Dns\Query;
|
|||
|
||||
use React\Dns\Model\Message;
|
||||
use React\Dns\Model\Record;
|
||||
use React\Promise\When;
|
||||
|
||||
class CachedExecutor implements ExecutorInterface
|
||||
{
|
||||
|
@ -18,14 +19,15 @@ class CachedExecutor implements ExecutorInterface
|
|||
|
||||
public function query($nameserver, Query $query)
|
||||
{
|
||||
$that = $this;
|
||||
$executor = $this->executor;
|
||||
$cache = $this->cache;
|
||||
|
||||
return $this->cache
|
||||
->lookup($query)
|
||||
->then(
|
||||
function ($cachedRecords) use ($query) {
|
||||
return $this->buildResponse($query, $cachedRecords);
|
||||
function ($cachedRecords) use ($that, $query) {
|
||||
return $that->buildResponse($query, $cachedRecords);
|
||||
},
|
||||
function () use ($executor, $cache, $nameserver, $query) {
|
||||
return $executor
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue