Just to point out that during the Scottish referendum No. 10 campaigned for remain, but had a plan already set for if Scotland voted to leave (it had a time table and everything). It is also the job of the ruling party to enact/negotiate any change in UK law (thats what they won an election to be able to do).