Optionally allow undo while staging

Change-Id: I93afcc0937d59c0367a36aa9a27b2e3fd27da6d8
Merge "Optionally allow undo while staging"