Added assertions for new flag and addressed review comments