completeErrorSafe method
Calls completeError only if ![isCompleted] and returns true
,
otherwise just returns false
.
Implementation
bool completeErrorSafe(Object error, [StackTrace? stackTrace]) {
if (!isCompleted) {
completeError(error, stackTrace);
return true;
}
return false;
}