Merge code and modify UI