Unverified Commit 101aad49 authored by Djorkaeff Alexandre's avatar Djorkaeff Alexandre Committed by GitHub
Browse files

[REGRESSION] HTTP Basic Auth (#2490)

parent 60dc128c
import { InteractionManager } from 'react-native';
import semver from 'semver';
import { Rocketchat as RocketchatClient } from '@rocket.chat/sdk';
import {
Rocketchat as RocketchatClient,
settings as RocketChatSettings
} from '@rocket.chat/sdk';
import { Q } from '@nozbe/watermelondb';
import AsyncStorage from '@react-native-community/async-storage';
import RNFetchBlob from 'rn-fetch-blob';
......@@ -111,7 +114,7 @@ const RocketChat = {
},
async getServerInfo(server) {
try {
const response = await RNFetchBlob.fetch('GET', `${ server }/api/info`);
const response = await RNFetchBlob.fetch('GET', `${ server }/api/info`, { ...RocketChatSettings.customHeaders });
try {
// Try to resolve as json
const jsonRes = response.json();
......
Supports Markdown
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