Skip to content

Commit

Permalink
Merge pull request #1716 from Bilb/fix-spinner-onion
Browse files Browse the repository at this point in the history
fix spinner for onion path loading dialog
  • Loading branch information
Bilb authored Jun 24, 2021
2 parents d7eb0d5 + 7fadfac commit 35b55df
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { useDispatch, useSelector } from 'react-redux';
import { StateType } from '../state/reducer';
import { SessionIcon, SessionIconButton, SessionIconSize, SessionIconType } from './session/icon';

import { SessionWrapperModal } from '../components/session/SessionWrapperModal';
import { SessionWrapperModal } from './session/SessionWrapperModal';

import ip2country from 'ip2country';
import countryLookup from 'country-code-lookup';
Expand All @@ -38,8 +38,8 @@ const OnionPathModalInner = () => {
const onionPath = useSelector(getFirstOnionPath);
// including the device and destination in calculation
const glowDuration = onionPath.length + 2;

if (!onionPath) {
console.warn('onionPath', onionPath);
if (!onionPath || onionPath.length === 0) {
return <SessionSpinner loading={true} />;
}

Expand Down
2 changes: 1 addition & 1 deletion ts/components/session/ActionsPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import { FSv2 } from '../../fileserver';
import { debounce } from 'lodash';
import { DURATION } from '../../session/constants';
import { actions as conversationActions } from '../../state/ducks/conversations';
import { ActionPanelOnionStatusLight, OnionPathModal } from '../OnionStatusDialog';
import { ActionPanelOnionStatusLight, OnionPathModal } from '../OnionStatusPathDialog';
import { EditProfileDialog } from '../EditProfileDialog';
import { SessionConfirm } from './SessionConfirm';
import {
Expand Down
2 changes: 1 addition & 1 deletion ts/components/session/ModalContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import { RemoveModeratorsDialog } from '../conversation/ModeratorsRemoveDialog';
import { UpdateGroupMembersDialog } from '../conversation/UpdateGroupMembersDialog';
import { UpdateGroupNameDialog } from '../conversation/UpdateGroupNameDialog';
import { EditProfileDialog } from '../EditProfileDialog';
import { OnionPathModal } from '../OnionStatusDialog';
import { OnionPathModal } from '../OnionStatusPathDialog';
import { UserDetailsDialog } from '../UserDetailsDialog';
import { SessionConfirm } from './SessionConfirm';
import { SessionNicknameDialog } from './SessionNicknameDialog';
Expand Down

0 comments on commit 35b55df

Please sign in to comment.