updated row reversal when adding prefilled rows