diff --git a/configcat-validator.py b/configcat-validator.py index a02d6d3..2104e63 100644 --- a/configcat-validator.py +++ b/configcat-validator.py @@ -51,7 +51,7 @@ def main(): sys.exit(1) if validation_result: - log.info("PASSED. everything's fine, didn't find any unused feature flags.") + log.info("PASSED. Everything's fine, didn't find any unused feature flags.") def str2bool(v): diff --git a/configcat/reference_validator/reference_validator.py b/configcat/reference_validator/reference_validator.py index fc7623f..6e1bd46 100644 --- a/configcat/reference_validator/reference_validator.py +++ b/configcat/reference_validator/reference_validator.py @@ -14,12 +14,12 @@ def validate(remote_keys, missing_references = remote_keys.difference(reference_keys) missing_remote_keys = reference_keys.difference(remote_keys) - log.warning( - "Found unused feature flags!") - result = True - if len(missing_references) > 0: + if len(missing_references) > 0 or len(missing_references) > 0: result = False + log.warning("Found unused feature flags!") + + if len(missing_references) > 0: log.debug( "Feature flag/Setting keys not found in source code (but present in ConfigCat): %s.", missing_references) @@ -27,7 +27,6 @@ def validate(remote_keys, log.warning("Clean up '%s' from ConfigCat Dashboard.", item) if len(missing_remote_keys) > 0: - result = False log.debug( "Feature flag/Setting keys not found in ConfigCat (but present in source code): %s.", missing_remote_keys) diff --git a/setup.py b/setup.py index c806c46..b6c06d0 100644 --- a/setup.py +++ b/setup.py @@ -1,6 +1,6 @@ import setuptools -version = "1.0.8" +version = "1.0.9" setuptools.setup( name='configcat-flag-reference-validator',