public function withAddedInterceptor(string $name, array $functions): self
    {
        if (!isset($this->interceptors[$name])) {
            $this->interceptors[$name] = [];
        }
        $this->interceptors[$name] = array_merge($this->interceptors[$name], $functions);

        return $this;
    }
public function withAddedInterceptor(string $name, array $functions): self
    {
        if (!isset($this->interceptors[$name])) {
            $this->interceptors[$name] = [];
        }
        $this->interceptors[$name] = array_merge($this->interceptors[$name], $functions);

        return $this;
    }
public function withAddedInterceptor ( string $ name , array $ functions ) : self { if ( ! isset ( $ this -> interceptors [ $ name ] ) ) { $ this -> interceptors [ $ name ] = [ ] ; } $ this -> interceptors [ $ name ] = array_merge ( $ this -> interceptors [ $ name ] , $ functions ) ; return $ this ; }
Add a function to the interceptor

@param string $name
@param callable|array $functions
@return self|$this
Add a function to the interceptor