fix delete flag