mirror of
https://github.com/leptos-rs/leptos
synced 2024-09-20 06:21:57 +00:00
fix: #[server]
macro error type detection (#2298)
In most cases when you return `Result<..., ServerFnError<E>>` this worked but when you tried `Result<..., leptos::ServerFnError<E>>` then it didn't.
This commit is contained in:
parent
830fba794e
commit
23bc892a24
1 changed files with 1 additions and 1 deletions
|
@ -638,7 +638,7 @@ fn err_type(return_ty: &Type) -> Result<Option<&GenericArgument>> {
|
|||
{
|
||||
if let Some(segment) = pat.path.segments.last() {
|
||||
if segment.ident == "ServerFnError" {
|
||||
let args = &pat.path.segments[0].arguments;
|
||||
let args = &segment.arguments;
|
||||
match args {
|
||||
// Result<T, ServerFnError>
|
||||
PathArguments::None => return Ok(None),
|
||||
|
|
Loading…
Reference in a new issue