Verified Commit 522bcc42 authored by staltz's avatar staltz

Refactor nodejs-project/index (rebase fixup this later)

parent 035e08e0
......@@ -14,13 +14,12 @@ const rnChannelPlugin = require('multiserver-rn-channel');
const NoauthTransformPlugin = require('multiserver/plugins/noauth');
const npip = require('non-private-ip');
const injectSsbConfig = require('ssb-config/inject');
const BluetoothManager = require('ssb-mobile-bluetooth-manager');
const bluetoothTransportAndPlugin = require('ssb-bluetooth');
import syncingPlugin = require('./plugins/syncing');
import blobsFromPathPlugin = require('./plugins/blobsFromPath');
import manifest = require('./manifest');
const BluetoothManager = require('ssb-mobile-bluetooth-manager');
const Bluetooth = require('ssb-bluetooth');
const appDataDir = rnBridge.app.datadir();
const ssbPath = path.resolve(appDataDir, '.ssb');
if (!fs.existsSync(ssbPath)) {
......@@ -82,7 +81,7 @@ function dhtTransport(_sbot: any) {
}
const bluetoothManager: any = BluetoothManager({
socketFolderPath: appDataDir
socketFolderPath: appDataDir,
});
require('scuttlebot/index')
......@@ -90,7 +89,7 @@ require('scuttlebot/index')
.use(rnChannelTransport)
.use(require('ssb-dht-invite'))
.use(dhtTransport)
.use(Bluetooth(bluetoothManager))
.use(bluetoothTransportAndPlugin(bluetoothManager))
.use(require('scuttlebot/plugins/master'))
.use(require('@staltz/sbot-gossip'))
.use(require('scuttlebot/plugins/replicate'))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment