Skip to content

Commit

Permalink
Revert "added initial version of mdns discovery"
Browse files Browse the repository at this point in the history
This reverts commit 4d5c137.
  • Loading branch information
ehsan6sha committed May 20, 2023
1 parent 93d2a87 commit dfff5ed
Show file tree
Hide file tree
Showing 4 changed files with 8,307 additions and 8,516 deletions.
2 changes: 1 addition & 1 deletion android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ repositories {
dependencies {
//noinspection GradleDynamicVersion
implementation "com.facebook.react:react-native:+" // From node_modules
implementation 'com.github.functionland:fula-build-aar:v1.6.0' // From jitpack.io
implementation 'com.github.functionland:fula-build-aar:1.2.1' // From jitpack.io
implementation 'com.github.functionland:wnfs-build-aar:v1.4.1' // From jitpack.io
implementation 'commons-io:commons-io:20030203.000550'
// implementation files('mobile.aar')
Expand Down
22 changes: 0 additions & 22 deletions android/src/main/java/land/fx/fula/FulaModule.java
Original file line number Diff line number Diff line change
Expand Up @@ -345,24 +345,6 @@ private void checkFailedActions(boolean retry, int timeout, Promise promise) thr
}
}

@ReactMethod
public void listPeersFound(Promise promise) {
ThreadUtils.runOnExecutor(() -> {
Log.d("ReactNative", "listPeersFound started");
try {
string res = this.fula.listPeersFound();

//JSONArray jsonArray = new JSONArray(res);
String s = new String(res, StandardCharsets.UTF_8);
Log.d("ReactNative", "ls: res = " + s);
promise.resolve(s);
} catch (Exception e) {
Log.d("get", e.getMessage());
promise.reject(e);
}
});
}

private boolean retryFailedActionsInternal(int timeout) throws Exception {
try {
Log.d("ReactNative", "retryFailedActionsInternal started");
Expand Down Expand Up @@ -734,11 +716,7 @@ public void writeFile(String fulaTargetFilename, String localFilename, Promise p
this.rootConfig = config;
this.encrypt_and_store_config();
if (this.fula != null) {
Log.d("ReactNative", "writeFile flsuhing");
this.fula.flush();
Log.d("ReactNative", "writeFile flsuhed");
} else {
Log.d("ReactNative", "writeFile Error: fula is null");
}
promise.resolve(config.getCid());
} else {
Expand Down
3 changes: 1 addition & 2 deletions example/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,7 @@ const App = () => {
203, 243, 211, 78, 120, 114, 199, 1, 197, 134, 6, 91, 87, 152,
];
const privateKeyString = "\\test";
//const bloxAddr = '/dns/relay.dev.fx.land/tcp/4001/p2p/12D3KooWDRrBaAfPwsGJivBoUw5fE7ZpDiyfUjqgiURq2DEcL835/p2p-circuit/p2p/12D3KooWD69C5yX91nPe3tz6HRiuw7Pia4xsxE9xv2CghoyK6MPK';
const bloxAddr = '/ip4/192.168.2.14/tcp/40001/p2p/12D3KooWD69C5yX91nPe3tz6HRiuw7Pia4xsxE9xv2CghoyK6MPK';
const bloxAddr = '/dns/relay.dev.fx.land/tcp/4001/p2p/12D3KooWDRrBaAfPwsGJivBoUw5fE7ZpDiyfUjqgiURq2DEcL835/p2p-circuit/p2p/12D3KooWD69C5yX91nPe3tz6HRiuw7Pia4xsxE9xv2CghoyK6MPK';
const newClient = async () => {
try {
return fula.newClient(
Expand Down
Loading

0 comments on commit dfff5ed

Please sign in to comment.