Resolved merge of leg script.