API behavior "was complete"
Opened this issue · 1 comments
hckhanh commented
What is the different between two behaviors in API section:
Behavior | Description |
---|---|
was successful | Returns whether last request was successful |
was complete | Returns whether last request was completed |
I already checked the Semantic UI repo but I only found was successful
behavior. Is it right?
IonutBajescu commented
The code for the two behaviours can be found here https://github.com/Semantic-Org/Semantic-UI/blob/master/src/definitions/behaviors/api.js#L340.
The difference between sucessful and complete is that complete
will return true even if the request completed but was rejected (such as when the server returned a 500 response, if I'm not mistaken).