Skip to content

Commit

Permalink
Fix raw JSON DDF load order for user location (dresden-elektronik#7851)
Browse files Browse the repository at this point in the history
If a system location DDF already existed the user location DDF wasn't picket up correctly.

The problem occured only for raw JSON DDFs not bundles.

Part of dresden-elektronik#7845
  • Loading branch information
manup authored Jul 22, 2024
1 parent 9e46fe3 commit 7945694
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions device_descriptions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1180,6 +1180,11 @@ const DeviceDescription &DeviceDescriptions::get(const Resource *resource, DDF_M
{
rawJsonIndex = matchedIndices[i];
}
else if (ddf1.storageLocation == deCONZ::DdfUserLocation && d->descriptions[rawJsonIndex].storageLocation == deCONZ::DdfLocation)
{
// already had a match but user location has more precedence than system location
rawJsonIndex = matchedIndices[i];
}
continue;
}

Expand Down

0 comments on commit 7945694

Please sign in to comment.