leach: update implementation