Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid logging AuthToken from transition links #5425

Merged
merged 1 commit into from
Sep 22, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion src/libs/Navigation/NavigationRoot.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,13 @@ class NavigationRoot extends Component {
}

const path = getPathFromState(state, linkingConfig.config);
Log.info('Navigating to route', false, {path});

// Don't log the route transitions from OldDot because they contain authTokens
if (path.includes('/transition/')) {
Log.info('Navigating from transition link from OldDot using short lived authToken');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually I don't think we need to log this immediately though so we can add a false like we are doing in the other call?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually wait theres no need, it's false by default: https://github.com/Expensify/expensify-common/blob/master/lib/Logger.jsx#L82

} else {
Log.info('Navigating to route', false, {path});
}
setCurrentURL(path);
}

Expand Down