src/Defer/Defer.php
public function defer(Closure $resolver, string $path)
    {
        if ($data = Arr::get($this->result, "data.{$path}")) {
            return $data;
        }

        if ($this->isDeferred($path) || ! $this->acceptFurtherDeferring) {
            return $this->resolve($resolver, $path);
        }

        $this->deferred[$path] = $resolver;
    }
public function defer(Closure $resolver, string $path)
    {
        if ($data = Arr::get($this->result, "data.{$path}")) {
            return $data;
        }

        if ($this->isDeferred($path) || ! $this->acceptFurtherDeferring) {
            return $this->resolve($resolver, $path);
        }

        $this->deferred[$path] = $resolver;
    }
public function defer ( Closure $ resolver , string $ path ) { if ( $ data = Arr :: get ( $ this -> result , "data.{$path}" ) ) { return $ data ; } if ( $ this -> isDeferred ( $ path ) || ! $ this -> acceptFurtherDeferring ) { return $ this -> resolve ( $ resolver , $ path ) ; } $ this -> deferred [ $ path ] = $ resolver ; }
Register deferred field.

@param  \Closure  $resolver
@param  string  $path
@return mixed
Register deferred field .