Fixed merge bugs.