fix: scope server pins by port (fumi-core rev 1468f3c)

This commit is contained in:
randogoth 2026-09-30 08:52:57 +03:00
parent 996e879509
commit 7d2a147fec
16 changed files with 109 additions and 79 deletions

View file

@ -291,10 +291,11 @@ class SmolStore {
// --- pins -------------------------------------------------------------------
/// Pins a server's static key (§4): sync, because it is one local write.
void pinServer(String host, String keyB32) =>
_ffi.pinServer(_native.store!, host, keyB32);
void pinServer(String host, String keyB32, int port) =>
_ffi.pinServer(_native.store!, host, keyB32, port);
String? serverPin(String host) => _ffi.serverPin(_native.store!, host);
String? serverPin(String host, int port) =>
_ffi.serverPin(_native.store!, host, port);
List<(String, String)> allPins() {
final rows = _ffi.pins(_native.store!);
@ -304,7 +305,8 @@ class SmolStore {
];
}
Future<void> unpinServer(String host) async => _native.unpinServer(host);
Future<void> unpinServer(String host, int port) async =>
_native.unpinServer(host, port);
// --- backups ----------------------------------------------------------------