src/Console/ElasticMigrateCommand.php
protected function isTargetIndexExists()
    {
        $targetIndex = $this->argument('target-index');

        $payload = (new RawPayload())
            ->set('index', $targetIndex)
            ->get();

        return ElasticClient::indices()
            ->exists($payload);
    }
protected function isTargetIndexExists()
    {
        $targetIndex = $this->argument('target-index');

        $payload = (new RawPayload())
            ->set('index', $targetIndex)
            ->get();

        return ElasticClient::indices()
            ->exists($payload);
    }
protected function isTargetIndexExists ( ) { $ targetIndex = $ this -> argument ( 'target-index' ) ; $ payload = ( new RawPayload ( ) ) -> set ( 'index' , $ targetIndex ) -> get ( ) ; return ElasticClient :: indices ( ) -> exists ( $ payload ) ; }
Checks if the target index exists.

@return bool
Checks if the target index exists .