fix flagmaster publish code