Skip to content

Commit

Permalink
get rid of HostedChannelHelpers since these functions now live on hc/…
Browse files Browse the repository at this point in the history
…package.scala.
  • Loading branch information
fiatjaf committed Aug 30, 2022
1 parent 1844237 commit 35faaad
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 58 deletions.
58 changes: 0 additions & 58 deletions shared/src/main/scala/hc/HostedChannelHelpers.scala

This file was deleted.

23 changes: 23 additions & 0 deletions shared/src/main/scala/hc/HostedChannelMessages.scala
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,29 @@ case class LastCrossSignedState(
)
}

object LastCrossSignedState {
def empty = LastCrossSignedState(
isHost = false,
refundScriptPubKey = ByteVector.empty,
initHostedChannel = InitHostedChannel(
maxHtlcValueInFlightMsat = UInt64(0),
htlcMinimumMsat = MilliSatoshi(0),
maxAcceptedHtlcs = 0,
channelCapacityMsat = MilliSatoshi(0),
initialClientBalanceMsat = MilliSatoshi(0)
),
blockDay = 0,
localBalanceMsat = MilliSatoshi(0),
remoteBalanceMsat = MilliSatoshi(0),
localUpdates = 0,
remoteUpdates = 0,
incomingHtlcs = List.empty,
outgoingHtlcs = List.empty,
remoteSigOfLocal = ByteVector64.Zeroes,
localSigOfRemote = ByteVector64.Zeroes
)
}

case class StateUpdate(
blockDay: Long,
localUpdates: Long,
Expand Down

0 comments on commit 35faaad

Please sign in to comment.