Adds edit functionality. bjmcmorran xwen2
Fixes merge conflicts.