Merge branch '593-bugfix-ext-json-serializer' into develop at commit 53699a9d27
This commit is contained in:
commit
76de1f8f0b
1 changed files with 8 additions and 0 deletions
|
|
@ -168,6 +168,14 @@ struct graphene_extension_from_variant_visitor
|
|||
template< typename T >
|
||||
void from_variant( const fc::variant& var, graphene::chain::extension<T>& value )
|
||||
{
|
||||
if( var.is_null() )
|
||||
return;
|
||||
if( var.is_array() )
|
||||
{
|
||||
FC_ASSERT( var.size() == 0 );
|
||||
return;
|
||||
}
|
||||
|
||||
graphene_extension_from_variant_visitor<T> vtor( var.get_object(), value.value );
|
||||
fc::reflector<T>::visit( vtor );
|
||||
FC_ASSERT( vtor.count_left == 0 ); // unrecognized extension throws here
|
||||
|
|
|
|||
Loading…
Reference in a new issue