diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2019-02-07 21:02:33 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2019-02-07 21:02:33 +0900 |
| commit | 5448c22031d66cc020323bf4c4d1701889a46485 (patch) | |
| tree | e14772d48d982c6a7d9cebeed497c16373e2e303 /src/server/api | |
| parent | Fix #4179 (diff) | |
| download | sharkey-5448c22031d66cc020323bf4c4d1701889a46485.tar.gz sharkey-5448c22031d66cc020323bf4c4d1701889a46485.tar.bz2 sharkey-5448c22031d66cc020323bf4c4d1701889a46485.zip | |
Revert 96bc17aa1014983d5e6bf8b4c05d898156995a0d
Diffstat (limited to 'src/server/api')
| -rw-r--r-- | src/server/api/endpoints/meta.ts | 6 | ||||
| -rw-r--r-- | src/server/api/endpoints/users/recommendation.ts | 2 | ||||
| -rw-r--r-- | src/server/api/streaming.ts | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/src/server/api/endpoints/meta.ts b/src/server/api/endpoints/meta.ts index d08d0b0734..91cb095c92 100644 --- a/src/server/api/endpoints/meta.ts +++ b/src/server/api/endpoints/meta.ts @@ -46,7 +46,7 @@ export default define(meta, (ps, me) => new Promise(async (res, rej) => { description: instance.description, langs: instance.langs, - secure: config.https.isJust(), + secure: config.https != null, machine: os.hostname(), os: os.platform(), node: process.version, @@ -83,9 +83,9 @@ export default define(meta, (ps, me) => new Promise(async (res, rej) => { registration: !instance.disableRegistration, localTimeLine: !instance.disableLocalTimeline, globalTimeLine: !instance.disableGlobalTimeline, - elasticsearch: config.elasticsearch.isJust(), + elasticsearch: config.elasticsearch ? true : false, recaptcha: instance.enableRecaptcha, - objectStorage: config.drive.storage === 'minio', + objectStorage: config.drive && config.drive.storage === 'minio', twitter: instance.enableTwitterIntegration, github: instance.enableGithubIntegration, discord: instance.enableDiscordIntegration, diff --git a/src/server/api/endpoints/users/recommendation.ts b/src/server/api/endpoints/users/recommendation.ts index d07c4b08f0..e3a03888b6 100644 --- a/src/server/api/endpoints/users/recommendation.ts +++ b/src/server/api/endpoints/users/recommendation.ts @@ -50,7 +50,7 @@ export default define(meta, (ps, me) => new Promise(async (res, rej) => { request({ url: url, - proxy: config.proxy.getOrElse(null), + proxy: config.proxy, timeout: timeout, json: true, followRedirect: true, diff --git a/src/server/api/streaming.ts b/src/server/api/streaming.ts index d70cec03dc..f8f3c0ff4a 100644 --- a/src/server/api/streaming.ts +++ b/src/server/api/streaming.ts @@ -23,10 +23,10 @@ module.exports = (server: http.Server) => { let ev: EventEmitter; - if (config.redis.isJust()) { + if (config.redis) { // Connect to Redis const subscriber = redis.createClient( - config.redis.get().port, config.redis.get().host); + config.redis.port, config.redis.host); subscriber.subscribe('misskey'); |