File tree Expand file tree Collapse file tree 2 files changed +20
-5
lines changed
app/src/main/java/to/bitkit Expand file tree Collapse file tree 2 files changed +20
-5
lines changed Original file line number Diff line number Diff line change @@ -40,9 +40,15 @@ internal object Env {
4040 val vssServerUrl
4141 get() = when (network) {
4242 Network .BITCOIN -> TODO (" VSS not implemented for mainnet" )
43+ // Network.REGTEST -> "http://localhost:5050/vss"
4344 else -> " https://bitkit.stag0.blocktank.to/vss_rs/"
4445 }
4546
47+ val lnurlAuthSeverUrl = when (network) {
48+ // Network.REGTEST -> "http://localhost:3000/auth"
49+ else -> " " // TODO implement LNURL-auth Server for other networks
50+ }
51+
4652 val vssStoreId
4753 get() = when (network) {
4854 Network .REGTEST -> " bitkit_regtest"
Original file line number Diff line number Diff line change @@ -113,11 +113,20 @@ class LightningService @Inject constructor(
113113
114114 ServiceQueue .LDK .background {
115115 node = try {
116- builder.buildWithVssStoreAndFixedHeaders(
117- vssUrl = Env .vssServerUrl,
118- storeId = vssStoreId,
119- fixedHeaders = emptyMap(),
120- )
116+ if (Env .lnurlAuthSeverUrl.isNotBlank()) {
117+ builder.buildWithVssStore(
118+ vssUrl = Env .vssServerUrl,
119+ storeId = vssStoreId,
120+ lnurlAuthServerUrl = Env .lnurlAuthSeverUrl,
121+ fixedHeaders = emptyMap(),
122+ )
123+ } else {
124+ builder.buildWithVssStoreAndFixedHeaders(
125+ vssUrl = Env .vssServerUrl,
126+ storeId = vssStoreId,
127+ fixedHeaders = emptyMap(),
128+ )
129+ }
121130 } catch (e: BuildException ) {
122131 throw LdkError (e)
123132 }
You can’t perform that action at this time.
0 commit comments