Open Nutomic opened 7 months ago
https://github.com/Nutomic/ibis/commit/6dd1711e11fb628038a5f368327c52ae4041af41 cleanly handles all backend errors. Still lots of unwrap in the frontend.
One of the biggest errors I see is related to #40
article_resource()
unwraps the result, without care for the error.
Thus, the return type must be changed from
Resource<Option<String>, ArticleView>
to Resource<Option<String>, Result<ArticleView, Error>>
The problem with this is that all other views depend on the the resource being the first type.
This means every view must be modified to support the new result type.
The only issue is that ArticleNav
depends on the first type.
Now honestly am stuck with my lack of rust knowledge.
Best open a pull request with the changes you have so far, that way I can have a look myself.
The project currently uses unwrap all over the place, meaning it will crash if anything goes wrong. Need to get rid of this, add proper error handling and forbid unwrap usage via clippy.