Skip to content

Commit

Permalink
Merge pull request #21475 from Expensify/marco-noDesktopSupportAnonym…
Browse files Browse the repository at this point in the history
…ousUsers

[No QA] Avoid calling OpenOldDotLink for anonymous users
  • Loading branch information
grgia authored Jun 28, 2023
2 parents b30cc02 + fcb49b2 commit 94e2656
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/components/DeeplinkWrapper/index.website.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import * as Browser from '../../libs/Browser';
import ONYXKEYS from '../../ONYXKEYS';
import * as Authentication from '../../libs/Authentication';
import DeeplinkRedirectLoadingIndicator from './DeeplinkRedirectLoadingIndicator';
import * as Session from '../../libs/actions/Session';

const propTypes = {
/** Children to render. */
Expand Down Expand Up @@ -61,6 +62,12 @@ class DeeplinkWrapper extends PureComponent {
this.openRouteInDesktopApp(expensifyDeeplinkUrl);
return;
}

// There's no support for anonymous users on desktop
if (Session.isAnonymousUser()) {
return;
}

Authentication.getShortLivedAuthToken()
.then((shortLivedAuthToken) => {
params.set('email', this.props.session.email);
Expand Down

0 comments on commit 94e2656

Please sign in to comment.