fixes another bug in #24