private PaymentChannelServer maybeInitPayments() {
if (payments != null)
return payments;
BigInteger minPayment = BigInteger.valueOf(defaultPricePerChunk * MIN_ACCEPTED_CHUNKS);
payments = new PaymentChannelServer(transactionBroadcaster, wallet, minPayment, new PaymentChannelServer.ServerConnection() {
@Override
public void sendToClient(Protos.TwoWayChannelMessage msg) {
Payfile.PayFileMessage.Builder m = Payfile.PayFileMessage.newBuilder();
m.setPayment(msg.toByteString());
m.setType(Payfile.PayFileMessage.Type.PAYMENT);