impl ProductList {
pub fn list() -> Self {
ProductList(result)
}
}```
from
to
```Rust
impl Product {
pub fn list() -> Self {
ProductList(result)
}
}```
then use `Product::list()` look better and don't repeat list two times
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Discussion on: Practical Rust Web Development - API Rest
For further actions, you may consider blocking this person and/or reporting abuse