diff --git a/doc/api/dcat/CatResult-class.html b/doc/api/dcat/CatResult-class.html index 3afea57..95cafd2 100644 --- a/doc/api/dcat/CatResult-class.html +++ b/doc/api/dcat/CatResult-class.html @@ -146,7 +146,7 @@

Methods

- addMessage(int exitCode, String message, {String? path}) + addMessage(String message, {String? path}) → void diff --git a/doc/api/dcat/CatResult/addMessage.html b/doc/api/dcat/CatResult/addMessage.html index 7daeea5..3298d43 100644 --- a/doc/api/dcat/CatResult/addMessage.html +++ b/doc/api/dcat/CatResult/addMessage.html @@ -53,8 +53,7 @@ void -addMessage(
  1. int exitCode,
  2. -
  3. String message,
  4. +addMessage(
    1. String message,
    2. {String? path}
    ) @@ -70,8 +69,8 @@

    Implementation

    -
    void addMessage(int exitCode, String message, {String? path}) {
    -  this.exitCode = exitCode;
    +  
    void addMessage(String message, {String? path}) {
    +  exitCode = exitFailure;
       if (path != null && path.isNotEmpty) {
         messages.add('$path: $message');
       } else {
    diff --git a/doc/api/dcat/cat.html b/doc/api/dcat/cat.html
    index bb1ec15..f912708 100644
    --- a/doc/api/dcat/cat.html
    +++ b/doc/api/dcat/cat.html
    @@ -93,10 +93,10 @@
       if (paths.isEmpty) {
         if (input != null) {
           try {
    -        await _writeStream(input, lastLine, output, numberNonBlank, showEnds,
    +        await _copyStream(input, lastLine, output, numberNonBlank, showEnds,
                 showLineNumbers, showNonPrinting, showTabs, squeezeBlank);
           } catch (e) {
    -        result.addMessage(exitFailure, _formatError(e));
    +        result.addMessage(_getErrorMessage(e));
           }
         }
       } else {
    @@ -108,10 +108,10 @@
             } else {
               stream = File(path).openRead();
             }
    -        await _writeStream(stream, lastLine, output, numberNonBlank, showEnds,
    +        await _copyStream(stream, lastLine, output, numberNonBlank, showEnds,
                 showLineNumbers, showNonPrinting, showTabs, squeezeBlank);
           } catch (e) {
    -        result.addMessage(exitFailure, _formatError(e), path: path);
    +        result.addMessage(_getErrorMessage(e), path: path);
           }
         }
       }