Heat the butter in a frying pan, add the chicken and fry on both sides until golden. Remove from the pan and set aside. Add the white leek slices to the pan and fry for 2–3 minutes until softened. Return the chicken to the pan, add the stock, cider and thyme, then season with salt and pepper. Bring to the boil, cover and simmer for 45 minutes until the chicken is cooked through.
Transfer the chicken to a plate. Stir the cornflour mix into the stock pan and bring to the boil, stirring until thickened, then take off the heat. Remove the skin and bones from the chicken, dice the meat and add to the sauce with the green leeks and mushrooms. Leave to cool.
Spoon the filling into the base of a 1.2 litre (2 pint) pie dish. Roll out the pastry between 2 sheets of clingfilm for the lid. Brush the rim of the dish with beaten egg.
Remove one sheet of clingfilm, lay the pastry over the dish, then remove the top sheet of clingfilm. Press the pastry on to the dish with fingers dusted with rice flour. Trim off the excess, then brush with beaten egg. Bake in a preheated oven, 190°C (375°F), Gas Mark 5, for 30–35 minutes until the pastry is golden and the filling is piping hot.