mirror of
https://github.com/tauri-apps/tauri.git
synced 2024-12-15 21:53:59 +03:00
chore: small tweak to the serde CommandArg impl for cargo 1.61.0-nightly
The nightly version 1.61.0 of Cargo is failing to generate JSON documentation for this implementation, so we're helping it a little bit by changing `Self` to `D` since that's where their assert is failing
This commit is contained in:
parent
34090bab8f
commit
66fe5d81bc
@ -49,7 +49,7 @@ pub trait CommandArg<'de, R: Runtime>: Sized {
|
||||
|
||||
/// Automatically implement [`CommandArg`] for any type that can be deserialized.
|
||||
impl<'de, D: Deserialize<'de>, R: Runtime> CommandArg<'de, R> for D {
|
||||
fn from_command(command: CommandItem<'de, R>) -> Result<Self, InvokeError> {
|
||||
fn from_command(command: CommandItem<'de, R>) -> Result<D, InvokeError> {
|
||||
let name = command.name;
|
||||
let arg = command.key;
|
||||
Self::deserialize(command).map_err(|e| crate::Error::InvalidArgs(name, arg, e).into())
|
||||
|
Loading…
Reference in New Issue
Block a user