Simplify filter check

This commit is contained in:
Clement 2019-02-05 17:02:19 -08:00
parent 5945823606
commit 8b32a62e2f
2 changed files with 2 additions and 10 deletions

View file

@ -2635,15 +2635,8 @@ bool EntityItem::matchesJSONFilters(const QJsonObject& jsonFilters) const {
static const QString SERVER_SCRIPTS_PROPERTY = "serverScripts";
foreach(const auto& property, jsonFilters.keys()) {
if (property == SERVER_SCRIPTS_PROPERTY && jsonFilters[property] == EntityQueryFilterSymbol::NonDefault) {
// check if this entity has a non-default value for serverScripts
if (_serverScripts != ENTITY_ITEM_DEFAULT_SERVER_SCRIPTS) {
return true;
} else {
return false;
}
}
if (jsonFilters[SERVER_SCRIPTS_PROPERTY] == EntityQueryFilterSymbol::NonDefault) {
return _serverScripts != ENTITY_ITEM_DEFAULT_SERVER_SCRIPTS;
}
// the json filter syntax did not match what we expected, return a match

View file

@ -493,7 +493,6 @@ void NetworkTexture::makeRequest() {
} else {
qWarning(networking) << "NetworkTexture::makeRequest() called while not in a valid state: " << _ktxResourceState;
}
}
void NetworkTexture::handleLocalRequestCompleted() {