diff --git a/mpcdf_build_status.py b/mpcdf_build_status.py
index 68ca063c1c8c68a8514f62be7a74f3b06536988f..05287e1f850361642b689b6e3a6a1be9c810dbbd 100644
--- a/mpcdf_build_status.py
+++ b/mpcdf_build_status.py
@@ -140,7 +140,7 @@ def do_mpcdf_build_status(self, subcmd, opts, *args):
     ignore_status = ignore_status.union(["disabled", "excluded", "succeeded"])
 
     def print_stdout(text=""):
-        if opts.only_count is None:
+        if not opts.only_count:
             print(text)
 
     count = dict()