optimizer: Remove unused flag added in d14b4a8

The definition and update of nested is not necesary, because it not used.