Make indent

This commit is contained in:
Eric Fischer
2017-08-28 14:01:57 -07:00
parent b7df68c164
commit 8d7f8af1d9
+5 -5
View File
@@ -8,7 +8,7 @@ int compare(mvt_value one, json_object *two, bool &fail) {
if (one.type == mvt_string) { if (one.type == mvt_string) {
if (two->type != JSON_STRING) { if (two->type != JSON_STRING) {
fail = true; fail = true;
return false; // string vs non-string return false; // string vs non-string
} }
return strcmp(one.string_value.c_str(), two->string); return strcmp(one.string_value.c_str(), two->string);
@@ -17,7 +17,7 @@ int compare(mvt_value one, json_object *two, bool &fail) {
if (one.type == mvt_double || one.type == mvt_float || one.type == mvt_int || one.type == mvt_uint || one.type == mvt_sint) { if (one.type == mvt_double || one.type == mvt_float || one.type == mvt_int || one.type == mvt_uint || one.type == mvt_sint) {
if (two->type != JSON_NUMBER) { if (two->type != JSON_NUMBER) {
fail = true; fail = true;
return false; // number vs non-number return false; // number vs non-number
} }
double v; double v;
@@ -48,7 +48,7 @@ int compare(mvt_value one, json_object *two, bool &fail) {
if (one.type == mvt_bool) { if (one.type == mvt_bool) {
if (two->type != JSON_TRUE && two->type != JSON_FALSE) { if (two->type != JSON_TRUE && two->type != JSON_FALSE) {
fail = true; fail = true;
return false; // bool vs non-bool return false; // bool vs non-bool
} }
bool b = two->type = JSON_TRUE; bool b = two->type = JSON_TRUE;
@@ -108,7 +108,7 @@ bool eval(std::map<std::string, mvt_value> const &feature, json_object *f) {
auto ff = feature.find(std::string(f->array[1]->string)); auto ff = feature.find(std::string(f->array[1]->string));
if (ff == feature.end()) { if (ff == feature.end()) {
return false; // not found: comparison is false return false; // not found: comparison is false
} }
bool fail = false; bool fail = false;
@@ -179,6 +179,6 @@ bool evaluate(std::map<std::string, mvt_value> const &feature, std::string const
if (f != NULL) { if (f != NULL) {
return eval(feature, f); return eval(feature, f);
} else { } else {
return true; // no filter for this layer; return true; // no filter for this layer;
} }
} }