Bug assertions fixed