Line a 20cm square tin with baking paper, leaving a slight overhang on two sides for easy lifting.
Place the crushed digestive biscuits, melted butter and caster sugar in a medium bowl. Mix well until the crumbs are evenly coated, then press the mixture firmly into the base of the prepared tin. Chill in the fridge while you make the next layer.
Roughly chop the pistachios if needed. In a medium saucepan over a medium heat, melt the unsalted butter. Stir in the tinned sweetened condensed milk, vanilla extract and salt. Bring to a gentle simmer, stirring constantly, and cook for 2–3 minutes until slightly thickened. Remove from the heat, then stir in the chopped pistachios.
Pour the pistachio mixture over the chilled base in an even layer. Return to the fridge and chill for at least 30 minutes, or until set.
Put the dark chocolate chips and remaining unsalted butter in a heatproof bowl. Melt in the microwave in 30-second bursts, stirring after each interval until smooth, or melt over a bain-marie. Pour the melted chocolate over the set pistachio layer and, if you like, sprinkle over extra chopped pistachios.
Chill in the fridge for 2–3 hours, or preferably overnight, until firm. Use the paper overhang to lift the block out of the tin, then cut into 16 squares. Store any leftovers in an airtight container in the fridge for up to 5 days.