Issue #23572: Fixed functools.singledispatch on classes with falsy metaclasses.

Patch by Ethan Furman.
diff --git a/Lib/functools.py b/Lib/functools.py
index 09df068..06a4ff1 100644
--- a/Lib/functools.py
+++ b/Lib/functools.py
@@ -567,7 +567,7 @@
                     break      # reject the current head, it appears later
             else:
                 break
-        if not candidate:
+        if candidate is None:
             raise RuntimeError("Inconsistent hierarchy")
         result.append(candidate)
         # remove the chosen candidate