Manual merge of semi-updated control code