Fix a breaking code change fro previous commit

Flags was added even though it was present