mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-18 16:44:32 +00:00
partial reversion of previous commit
This commit is contained in:
parent
615fdfb5bf
commit
b6dd28562b
2 changed files with 1 additions and 11 deletions
|
@ -108,11 +108,6 @@ Future<MoneroNodeConnectionResponse> testMoneroNodeConnection(
|
|||
await socket.connect();
|
||||
await socket.connectTo(uri.host, uri.port);
|
||||
|
||||
// If this is an onion node and connectTo didn't throw, it's a success.
|
||||
// if (uri.host.endsWith(".onion")) {
|
||||
// return MoneroNodeConnectionResponse(null, null, null, true);
|
||||
// }
|
||||
|
||||
final body = utf8.encode(
|
||||
jsonEncode({
|
||||
"jsonrpc": "2.0",
|
||||
|
|
|
@ -40,17 +40,12 @@ Future<bool> _xmrHelper(
|
|||
final String path = uri.path.isEmpty ? "/json_rpc" : uri.path;
|
||||
|
||||
final uriString = "${uri.scheme}://${uri.host}:${port ?? 0}$path";
|
||||
final uriString = uri.host.endsWith(".onion")
|
||||
? "${uri.toString()}:$port$path"
|
||||
: uri.hasScheme
|
||||
? uri.toString()
|
||||
: "${data.useSSL! ? "https" : "http"}://$url:$port$path";
|
||||
|
||||
final response = await testMoneroNodeConnection(
|
||||
Uri.parse(uriString),
|
||||
false,
|
||||
proxyInfo: proxyInfo,
|
||||
).timeout(Duration(seconds: proxyInfo != null ? 30 : 10));
|
||||
);
|
||||
|
||||
if (response.cert != null) {
|
||||
if (context.mounted) {
|
||||
|
|
Loading…
Reference in a new issue