Skip to content

Commit

Permalink
[REGRESSION] HTTP Basic Auth (#2490)
Browse files Browse the repository at this point in the history
  • Loading branch information
djorkaeffalexandre authored Sep 24, 2020
1 parent 60dc128 commit 101aad4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions app/lib/rocketchat.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
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';
Expand Down Expand Up @@ -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();
Expand Down

0 comments on commit 101aad4

Please sign in to comment.