Fix silly bugs in d017637a1e64425db81e3b511d6c20f96c35b8f5