When you have finished bleeding the system through the bleeder valve, let the bike sit a few minutes, have a rag and a 12mm wrench ready, put the wrench on the banjo bolt at the master on the handle bars, wrap the rag around the wrench and bolt to catch any fluid that comes out, then pull in the lever and hold it in, then loosen the banjo bolt, you will hear some air escape, repeat this a few times and you should be good to go.
Richard