Fix allowable property check on add in AeroGearConnectorService.handle

This commit is contained in:
Ville Skyttä 2016-07-29 19:37:05 +03:00 committed by Clebert Suconic
parent 9073e4cd74
commit a1fd6f56ba
1 changed files with 3 additions and 2 deletions

View File

@ -258,9 +258,10 @@ public class AeroGearConnectorService implements ConnectorService, Consumer, Mes
Set<SimpleString> propertyNames = message.getPropertyNames();
for (SimpleString propertyName : propertyNames) {
if (propertyName.toString().startsWith("AEROGEAR_") && !AeroGearConstants.ALLOWABLE_PROPERTIES.contains(propertyName)) {
String nameString = propertyName.toString();
if (nameString.startsWith("AEROGEAR_") && !AeroGearConstants.ALLOWABLE_PROPERTIES.contains(nameString)) {
Object property = message.getTypedProperties().getProperty(propertyName);
builder.attribute(propertyName.toString(), property.toString());
builder.attribute(nameString, property.toString());
}
}