protected function buildMessages(array $flashes, $type)
    {
        $messages = '';
        foreach ($flashes as $msg) {
            $messages .= $this->template->wrapMessage($msg);
        }

        return $this->template->wrapMessages($messages, $type);
    }
protected function buildMessages(array $flashes, $type)
    {
        $messages = '';
        foreach ($flashes as $msg) {
            $messages .= $this->template->wrapMessage($msg);
        }

        return $this->template->wrapMessages($messages, $type);
    }
protected function buildMessages ( array $ flashes , $ type ) { $ messages = '' ; foreach ( $ flashes as $ msg ) { $ messages .= $ this -> template -> wrapMessage ( $ msg ) ; } return $ this -> template -> wrapMessages ( $ messages , $ type ) ; }
Builds messages for a single type.

@param array  $flashes - array of messages to show
@param string $type    - message type: success, info, warning, error

@return string - HTML with flash messages
Builds messages for a single type .