forked from loafle/openapi-generator-original
Update modelbase-header.mustache (#15453)
Fixes warning in ModelBase.h warning: loop variable 'jitem' creates a copy from type 'const web::json::value' [-Wrange-loop-construct]
This commit is contained in:
@@ -233,7 +233,7 @@ bool ModelBase::fromJson( const web::json::value& val, std::vector<T> &outVal )
|
||||
bool ok = true;
|
||||
if (val.is_array())
|
||||
{
|
||||
for (const auto jitem : val.as_array())
|
||||
for (const web::json::value & jitem : val.as_array())
|
||||
{
|
||||
T item;
|
||||
ok &= fromJson(jitem, item);
|
||||
|
||||
Reference in New Issue
Block a user