Skip to content
This repository was archived by the owner on Jun 28, 2021. It is now read-only.

Commit 60fd675

Browse files
committed
fix
1 parent 712dbcb commit 60fd675

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/server/config/express.js

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const proxyApi = httpProxy.createProxyServer({
1818
});
1919

2020
const proxyOneQuran = httpProxy.createProxyServer({
21-
target: 'http://quranicaudio.com',
21+
target: process.env.ONE_QURAN_URL,
2222
secure: false,
2323
proxyTimeout: 15000,
2424
autoRewrite: true,
@@ -49,15 +49,10 @@ proxyOneQuran.on('error', (error, req, res) => {
4949
res.end(JSON.stringify(json));
5050
});
5151

52-
proxyOneQuran.on('proxyRes', function (proxyRes, req, res) {
53-
console.log('RAW Response from the target', JSON.stringify(proxyRes.headers, true, 2));
54-
});
55-
5652
export default function(server) {
5753
server.use(logger('dev'));
5854
// Must be first thing. See: https://github.com/nodejitsu/node-http-proxy/issues/180#issuecomment-3677221
5955
server.use('/onequran', (req, res) => {
60-
console.log(process.env.ONE_QURAN_URL);
6156
proxyOneQuran.web(req, res);
6257
});
6358

0 commit comments

Comments
 (0)