Added ability to detect and handle conflicts