protected function displayListOfAllCommands(Collection $handlers): Response
    {
        $attachmentFields = $handlers
            ->sort(function (SignatureHandler $handlerA, SignatureHandler $handlerB) {
                return strcmp($handlerA->getFullCommand(), $handlerB->getFullCommand());
            })
            ->map(function (SignatureHandler $handler) {
                return AttachmentField::create($handler->getFullCommand(), $handler->getDescription());
            })
            ->all();

        return $this->respondToSlack('Available commands:')
            ->withAttachment(
                Attachment::create()
                    ->setColor('good')
                    ->setFields($attachmentFields)
            );
    }
protected function displayListOfAllCommands(Collection $handlers): Response
    {
        $attachmentFields = $handlers
            ->sort(function (SignatureHandler $handlerA, SignatureHandler $handlerB) {
                return strcmp($handlerA->getFullCommand(), $handlerB->getFullCommand());
            })
            ->map(function (SignatureHandler $handler) {
                return AttachmentField::create($handler->getFullCommand(), $handler->getDescription());
            })
            ->all();

        return $this->respondToSlack('Available commands:')
            ->withAttachment(
                Attachment::create()
                    ->setColor('good')
                    ->setFields($attachmentFields)
            );
    }
protected function displayListOfAllCommands ( Collection $ handlers ) : Response { $ attachmentFields = $ handlers -> sort ( function ( SignatureHandler $ handlerA , SignatureHandler $ handlerB ) { return strcmp ( $ handlerA -> getFullCommand ( ) , $ handlerB -> getFullCommand ( ) ) ; } ) -> map ( function ( SignatureHandler $ handler ) { return AttachmentField :: create ( $ handler -> getFullCommand ( ) , $ handler -> getDescription ( ) ) ; } ) -> all ( ) ; return $ this -> respondToSlack ( 'Available commands:' ) -> withAttachment ( Attachment :: create ( ) -> setColor ( 'good' ) -> setFields ( $ attachmentFields ) ) ; }
Show a list of all available handlers.

@param  Collection $handlers
@return Response
Show a list of all available handlers .