add assert for debug