From 5369694b4de6bd4561108e156d2ae3ee1de1cc2f Mon Sep 17 00:00:00 2001 From: M Date: Tue, 24 Mar 2026 09:53:31 +1100 Subject: [PATCH] refactor: move NamecoinSettings and NamecoinResolveState to commons module Eliminates code duplication between Android and Desktop: - Move NamecoinSettings to commons/model/nip05DnsIdentifiers/namecoin/ (with @Serializable and @Stable annotations) - Extract NamecoinResolveState sealed class to its own file in commons - Move NamecoinSettingsTest to commons (shared by both platforms) - Replace Android NamecoinSettings.kt with a typealias to commons - Update all imports in Desktop and Android modules - Remove debug println statements from ImportFollowListDialog and Main --- .../service/namecoin/NamecoinNameService.kt | 18 +- .../service/namecoin/NamecoinSettingsTest.kt | 181 ------------------ .../namecoin/NamecoinResolveState.kt | 40 ++++ .../namecoin/NamecoinSettings.kt | 4 +- .../namecoin/NamecoinSettingsTest.kt | 6 +- .../namecoin/DesktopNamecoinNameService.kt | 19 +- .../namecoin/DesktopNamecoinPreferences.kt | 1 + .../desktop/ui/ImportFollowListDialog.kt | 9 - .../amethyst/desktop/ui/SearchScreen.kt | 2 +- .../ui/settings/NamecoinSettingsSection.kt | 2 +- 10 files changed, 52 insertions(+), 230 deletions(-) delete mode 100644 amethyst/src/test/java/com/vitorpamplona/amethyst/service/namecoin/NamecoinSettingsTest.kt create mode 100644 commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinResolveState.kt rename {desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service => commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers}/namecoin/NamecoinSettings.kt (96%) rename {desktopApp/src/jvmTest/kotlin/com/vitorpamplona/amethyst/desktop/service => commons/src/commonTest/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers}/namecoin/NamecoinSettingsTest.kt (97%) diff --git a/amethyst/src/main/java/com/vitorpamplona/amethyst/service/namecoin/NamecoinNameService.kt b/amethyst/src/main/java/com/vitorpamplona/amethyst/service/namecoin/NamecoinNameService.kt index b37a4832c..b16852dbc 100644 --- a/amethyst/src/main/java/com/vitorpamplona/amethyst/service/namecoin/NamecoinNameService.kt +++ b/amethyst/src/main/java/com/vitorpamplona/amethyst/service/namecoin/NamecoinNameService.kt @@ -20,6 +20,7 @@ */ package com.vitorpamplona.amethyst.service.namecoin +import com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin.NamecoinResolveState import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.DEFAULT_ELECTRUMX_SERVERS import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumXClient import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumxServer @@ -151,20 +152,3 @@ class NamecoinNameService( */ suspend fun clearCache() = cache.clear() } - -/** - * Observable state for a Namecoin resolution in progress. - */ -sealed class NamecoinResolveState { - data object Loading : NamecoinResolveState() - - data class Resolved( - val result: NamecoinNostrResult, - ) : NamecoinResolveState() - - data object NotFound : NamecoinResolveState() - - data class Error( - val message: String, - ) : NamecoinResolveState() -} diff --git a/amethyst/src/test/java/com/vitorpamplona/amethyst/service/namecoin/NamecoinSettingsTest.kt b/amethyst/src/test/java/com/vitorpamplona/amethyst/service/namecoin/NamecoinSettingsTest.kt deleted file mode 100644 index 661caca6e..000000000 --- a/amethyst/src/test/java/com/vitorpamplona/amethyst/service/namecoin/NamecoinSettingsTest.kt +++ /dev/null @@ -1,181 +0,0 @@ -/* - * Copyright (c) 2025 Vitor Pamplona - * - * Permission is hereby granted, free of charge, to any person obtaining a copy of - * this software and associated documentation files (the "Software"), to deal in - * the Software without restriction, including without limitation the rights to use, - * copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the - * Software, and to permit persons to whom the Software is furnished to do so, - * subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS - * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR - * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN - * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION - * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - */ -package com.vitorpamplona.amethyst.service.namecoin - -import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumxServer -import org.junit.Assert.assertEquals -import org.junit.Assert.assertFalse -import org.junit.Assert.assertNotNull -import org.junit.Assert.assertNull -import org.junit.Assert.assertTrue -import org.junit.Test - -class NamecoinSettingsTest { - // ── Server string parsing ────────────────────────────────────────── - - @Test - fun `parses host colon port as TLS`() { - val s = NamecoinSettings.parseServerString("example.com:50006") - assertNotNull(s) - assertEquals("example.com", s!!.host) - assertEquals(50006, s.port) - assertTrue(s.useSsl) - } - - @Test - fun `parses host colon port colon tcp as plaintext`() { - val s = NamecoinSettings.parseServerString("example.com:50001:tcp") - assertNotNull(s) - assertEquals("example.com", s!!.host) - assertEquals(50001, s.port) - assertFalse(s.useSsl) - } - - @Test - fun `parses onion address`() { - val s = NamecoinSettings.parseServerString("abc123def.onion:50001:tcp") - assertNotNull(s) - assertEquals("abc123def.onion", s!!.host) - assertEquals(50001, s.port) - assertFalse(s.useSsl) - assertTrue(s.usePinnedTrustStore) - } - - @Test - fun `trims whitespace`() { - val s = NamecoinSettings.parseServerString(" example.com : 50006 ") - assertNotNull(s) - assertEquals("example.com", s!!.host) - assertEquals(50006, s.port) - } - - @Test - fun `rejects empty host`() { - assertNull(NamecoinSettings.parseServerString(":50006")) - } - - @Test - fun `rejects invalid port`() { - assertNull(NamecoinSettings.parseServerString("example.com:abc")) - assertNull(NamecoinSettings.parseServerString("example.com:0")) - assertNull(NamecoinSettings.parseServerString("example.com:99999")) - } - - @Test - fun `rejects no port`() { - assertNull(NamecoinSettings.parseServerString("example.com")) - } - - // ── Format round-trip ────────────────────────────────────────────── - - @Test - fun `formats TLS server without suffix`() { - val server = ElectrumxServer("example.com", 50006, true) - assertEquals("example.com:50006", NamecoinSettings.formatServerString(server)) - } - - @Test - fun `formats TCP server with tcp suffix`() { - val server = ElectrumxServer("example.com", 50001, false) - assertEquals("example.com:50001:tcp", NamecoinSettings.formatServerString(server)) - } - - @Test - fun `round-trips server string through parse and format`() { - val original = "myserver.onion:50001:tcp" - val parsed = NamecoinSettings.parseServerString(original)!! - val formatted = NamecoinSettings.formatServerString(parsed) - assertEquals(original, formatted) - } - - // ── toElectrumxServers ───────────────────────────────────────────── - - @Test - fun `returns null when no custom servers`() { - val settings = NamecoinSettings(customServers = emptyList()) - assertNull(settings.toElectrumxServers()) - } - - @Test - fun `returns parsed list for valid custom servers`() { - val settings = - NamecoinSettings( - customServers = - listOf( - "server1.com:50006", - "server2.onion:50001:tcp", - ), - ) - val servers = settings.toElectrumxServers() - assertNotNull(servers) - assertEquals(2, servers!!.size) - assertEquals("server1.com", servers[0].host) - assertTrue(servers[0].useSsl) - assertEquals("server2.onion", servers[1].host) - assertFalse(servers[1].useSsl) - assertTrue(servers[1].usePinnedTrustStore) - } - - @Test - fun `skips invalid entries in custom server list`() { - val settings = - NamecoinSettings( - customServers = - listOf( - "valid.com:50006", - "invalid", // no port - "also-invalid:abc", // non-numeric port - ), - ) - val servers = settings.toElectrumxServers() - assertNotNull(servers) - assertEquals(1, servers!!.size) - assertEquals("valid.com", servers[0].host) - } - - @Test - fun `returns null when all custom servers are invalid`() { - val settings = NamecoinSettings(customServers = listOf("bad", "also-bad")) - assertNull(settings.toElectrumxServers()) - } - - // ── hasCustomServers flag ────────────────────────────────────────── - - @Test - fun `hasCustomServers is false when empty`() { - assertFalse(NamecoinSettings().hasCustomServers) - } - - @Test - fun `hasCustomServers is true when populated`() { - assertTrue(NamecoinSettings(customServers = listOf("x:1")).hasCustomServers) - } - - // ── Default settings ─────────────────────────────────────────────── - - @Test - fun `default settings are enabled with no custom servers`() { - val d = NamecoinSettings.DEFAULT - assertTrue(d.enabled) - assertTrue(d.customServers.isEmpty()) - assertFalse(d.hasCustomServers) - } -} diff --git a/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinResolveState.kt b/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinResolveState.kt new file mode 100644 index 000000000..6fffe789c --- /dev/null +++ b/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinResolveState.kt @@ -0,0 +1,40 @@ +/* + * Copyright (c) 2025 Vitor Pamplona + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of + * this software and associated documentation files (the "Software"), to deal in + * the Software without restriction, including without limitation the rights to use, + * copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the + * Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN + * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION + * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ +package com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin + +import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.NamecoinNostrResult + +/** + * Observable state for a Namecoin resolution in progress. + */ +sealed class NamecoinResolveState { + data object Loading : NamecoinResolveState() + + data class Resolved( + val result: NamecoinNostrResult, + ) : NamecoinResolveState() + + data object NotFound : NamecoinResolveState() + + data class Error( + val message: String, + ) : NamecoinResolveState() +} diff --git a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/NamecoinSettings.kt b/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinSettings.kt similarity index 96% rename from desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/NamecoinSettings.kt rename to commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinSettings.kt index 3bd73046c..6d7796d09 100644 --- a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/NamecoinSettings.kt +++ b/commons/src/commonMain/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinSettings.kt @@ -18,10 +18,11 @@ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -package com.vitorpamplona.amethyst.desktop.service.namecoin +package com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin import androidx.compose.runtime.Stable import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumxServer +import kotlinx.serialization.Serializable /** * Immutable data class representing the current Namecoin resolution config. @@ -30,6 +31,7 @@ import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumxServer * hardcoded defaults are ignored. This gives privacy-conscious users full * control over which ElectrumX servers observe their name lookups. */ +@Serializable @Stable data class NamecoinSettings( /** Whether Namecoin resolution is enabled at all. */ diff --git a/desktopApp/src/jvmTest/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/NamecoinSettingsTest.kt b/commons/src/commonTest/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinSettingsTest.kt similarity index 97% rename from desktopApp/src/jvmTest/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/NamecoinSettingsTest.kt rename to commons/src/commonTest/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinSettingsTest.kt index ea578196c..6cf693a6c 100644 --- a/desktopApp/src/jvmTest/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/NamecoinSettingsTest.kt +++ b/commons/src/commonTest/kotlin/com/vitorpamplona/amethyst/commons/model/nip05DnsIdentifiers/namecoin/NamecoinSettingsTest.kt @@ -18,7 +18,7 @@ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -package com.vitorpamplona.amethyst.desktop.service.namecoin +package com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumxServer import org.junit.Assert.assertEquals @@ -56,7 +56,7 @@ class NamecoinSettingsTest { assertEquals("abc123def.onion", s!!.host) assertEquals(50001, s.port) assertFalse(s.useSsl) - assertTrue(s.trustAllCerts) + assertTrue(s.usePinnedTrustStore) } @Test @@ -129,7 +129,7 @@ class NamecoinSettingsTest { assertTrue(servers[0].useSsl) assertEquals("server2.onion", servers[1].host) assertFalse(servers[1].useSsl) - assertTrue(servers[1].trustAllCerts) + assertTrue(servers[1].usePinnedTrustStore) } @Test diff --git a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/DesktopNamecoinNameService.kt b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/DesktopNamecoinNameService.kt index a56bf22cf..a9ef46e63 100644 --- a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/DesktopNamecoinNameService.kt +++ b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/DesktopNamecoinNameService.kt @@ -20,6 +20,8 @@ */ package com.vitorpamplona.amethyst.desktop.service.namecoin +import com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin.NamecoinResolveState +import com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin.NamecoinSettings import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.DEFAULT_ELECTRUMX_SERVERS import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumXClient import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumxServer @@ -135,20 +137,3 @@ class DesktopNamecoinNameService( */ suspend fun clearCache() = cache.clear() } - -/** - * Observable state for a Namecoin resolution in progress. - */ -sealed class NamecoinResolveState { - data object Loading : NamecoinResolveState() - - data class Resolved( - val result: NamecoinNostrResult, - ) : NamecoinResolveState() - - data object NotFound : NamecoinResolveState() - - data class Error( - val message: String, - ) : NamecoinResolveState() -} diff --git a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/DesktopNamecoinPreferences.kt b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/DesktopNamecoinPreferences.kt index 4e419a8df..c9df87f3c 100644 --- a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/DesktopNamecoinPreferences.kt +++ b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/service/namecoin/DesktopNamecoinPreferences.kt @@ -20,6 +20,7 @@ */ package com.vitorpamplona.amethyst.desktop.service.namecoin +import com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin.NamecoinSettings import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.ElectrumxServer import com.fasterxml.jackson.module.kotlin.jacksonObjectMapper import com.fasterxml.jackson.module.kotlin.readValue diff --git a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/ImportFollowListDialog.kt b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/ImportFollowListDialog.kt index 93d1695ef..bfd1ffaea 100644 --- a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/ImportFollowListDialog.kt +++ b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/ImportFollowListDialog.kt @@ -193,7 +193,6 @@ fun ImportFollowListDialog( // Use connected relays only — available relays may include disconnected ones val relays = relayManager.connectedRelays.value - println("[ImportFollows] Subscribing for kind 3 of $pubkey on ${relays.size} connected relays: $relays") if (relays.isEmpty()) { importState = ImportState.Error("No relays connected. Check your relay settings.") @@ -217,7 +216,6 @@ fun ImportFollowListDialog( relay: NormalizedRelayUrl, forFilters: List?, ) { - println("[ImportFollows] Received event kind=${event.kind} from $relay id=${event.id.take(12)}") if (event.kind == ContactListEvent.KIND && !receivedContactList) { receivedContactList = true val contactList = ContactListEvent( @@ -314,7 +312,6 @@ fun ImportFollowListDialog( relay: NormalizedRelayUrl, forFilters: List?, ) { - println("[ImportFollows] EOSE from $relay receivedContactList=$receivedContactList") } }, ) @@ -357,7 +354,6 @@ fun ImportFollowListDialog( try { // Try raw hex pubkey first (exact 64-char hex) if (trimmed.length == 64 && trimmed.matches(Regex("^[0-9a-fA-F]{64}$"))) { - println("[ImportFollows] Resolved raw hex: ${trimmed.take(16)}...") importState = ImportState.IdentifierResolved(trimmed.lowercase()) return@launch } @@ -366,7 +362,6 @@ fun ImportFollowListDialog( if (trimmed.startsWith("npub1") || trimmed.startsWith("nprofile1") || trimmed.startsWith("nsec1")) { val bech32Result = decodePublicKeyAsHexOrNull(trimmed) if (bech32Result != null && bech32Result.length == 64) { - println("[ImportFollows] Resolved bech32 to ${bech32Result.take(16)}...") importState = ImportState.IdentifierResolved(bech32Result) return@launch } @@ -376,10 +371,8 @@ fun ImportFollowListDialog( // Try Namecoin (.bit, d/, id/) if (NamecoinNameResolver.isNamecoinIdentifier(trimmed) && namecoinService != null) { - println("[ImportFollows] Resolving Namecoin identifier: $trimmed") val result = namecoinService.resolvePubkey(trimmed) if (result != null && result.length == 64) { - println("[ImportFollows] Namecoin resolved to ${result.take(16)}...") importState = ImportState.IdentifierResolved(result) return@launch } @@ -389,10 +382,8 @@ fun ImportFollowListDialog( // Try NIP-05 HTTP (user@domain) if (trimmed.contains("@")) { - println("[ImportFollows] Resolving NIP-05 HTTP: $trimmed") val result = resolveNip05Http(trimmed) if (result != null && result.length == 64) { - println("[ImportFollows] NIP-05 resolved to ${result.take(16)}...") importState = ImportState.IdentifierResolved(result) return@launch } diff --git a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/SearchScreen.kt b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/SearchScreen.kt index 89a369ba6..9fa686ba2 100644 --- a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/SearchScreen.kt +++ b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/SearchScreen.kt @@ -105,7 +105,7 @@ import com.vitorpamplona.amethyst.desktop.ui.search.SearchSyncBanner import com.vitorpamplona.amethyst.desktop.service.namecoin.DesktopNamecoinNameService import com.vitorpamplona.amethyst.desktop.service.namecoin.LocalNamecoinPreferences import com.vitorpamplona.amethyst.desktop.service.namecoin.LocalNamecoinService -import com.vitorpamplona.amethyst.desktop.service.namecoin.NamecoinResolveState +import com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin.NamecoinResolveState import com.vitorpamplona.quartz.nip01Core.metadata.MetadataEvent import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.NamecoinNameResolver import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.NamecoinResolveOutcome diff --git a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/settings/NamecoinSettingsSection.kt b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/settings/NamecoinSettingsSection.kt index 80aa897c4..3368ccda1 100644 --- a/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/settings/NamecoinSettingsSection.kt +++ b/desktopApp/src/jvmMain/kotlin/com/vitorpamplona/amethyst/desktop/ui/settings/NamecoinSettingsSection.kt @@ -66,7 +66,7 @@ import androidx.compose.ui.text.font.FontWeight import androidx.compose.ui.text.style.TextOverflow import androidx.compose.ui.unit.dp import androidx.compose.ui.unit.sp -import com.vitorpamplona.amethyst.desktop.service.namecoin.NamecoinSettings +import com.vitorpamplona.amethyst.commons.model.nip05DnsIdentifiers.namecoin.NamecoinSettings import com.vitorpamplona.quartz.nip05DnsIdentifiers.namecoin.DEFAULT_ELECTRUMX_SERVERS /**