Skip to content

Commit

Permalink
chore: Proxy JsonSchema::schema_name to the original implementation (n…
Browse files Browse the repository at this point in the history
  • Loading branch information
dj8yfo authored Jun 29, 2024
1 parent 96c277b commit d5903b7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions near-sdk-macros/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -649,9 +649,7 @@ pub fn derive_near_schema(#[allow(unused)] input: TokenStream) -> TokenStream {
#[automatically_derived]
impl #generics #near_sdk_crate::schemars::JsonSchema for #input_ident_proxy #generics #where_clause {
fn schema_name() -> ::std::string::String {
// TODO: consider replacing with
// <#input_ident #generics as #near_sdk_crate::schemars::JsonSchema>::schema_name()
stringify!(#input_ident #generics).to_string()
<#input_ident #generics as #near_sdk_crate::schemars::JsonSchema>::schema_name()
}

fn json_schema(gen: &mut #near_sdk_crate::schemars::gen::SchemaGenerator) -> #near_sdk_crate::schemars::schema::Schema {
Expand Down

0 comments on commit d5903b7

Please sign in to comment.