Fix how local creds are checked (#1106)
diff --git a/app/addons/replication/components/newreplication.js b/app/addons/replication/components/newreplication.js
index 8a1fd7f..38ca807 100644
--- a/app/addons/replication/components/newreplication.js
+++ b/app/addons/replication/components/newreplication.js
@@ -12,7 +12,7 @@
import base64 from 'base-64';
import React from 'react';
-import app from '../../../app';
+import Helpers from '../../../helpers';
import {json} from '../../../core/ajax';
import FauxtonAPI from '../../../core/api';
import {ReplicationSource} from './source';
@@ -101,7 +101,7 @@
}
checkCredentials(username, password) {
- return json(app.host + '/', 'GET', {
+ return json(Helpers.getServerUrl('/'), 'GET', {
credentials: 'omit',
headers: {
'Authorization':'Basic ' + base64.encode(username + ':' + password)