Fix AssertionError

Tested