toString method

  1. @override
String toString()
override

The toString method that returns a String containing both the errorCode and the message

Implementation

@override
String toString() {
  return '[$errorCode] $message';
}