Fixed a bug which prevented edits from working correctly