Fix flags init

/cc @matthew-andrews @aintgoin2goa