Skip to content

Commit

Permalink
fix syntax error
Browse files Browse the repository at this point in the history
  • Loading branch information
Amy Chen authored and Amy Chen committed Jul 11, 2022
1 parent 037c259 commit b190b4a
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions src/components/Launch.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,15 @@ export default function Launch() {
const [error, setError] = React.useState('');

React.useEffect(() => {

if (process.env.REACT_APP_BACKEND_URL) {
const authURL = `${process.env.REACT_APP_BACKEND_URL}/auth/auth-info`;
} else {
const authURL = 'launch-context.json';
}
let authURL = 'launch-context.json';
if (process.env.REACT_APP_BACKEND_URL) {
authURL = `${process.env.REACT_APP_BACKEND_URL}/auth/auth-info`;
}
const urlParams = new URLSearchParams(window.location.search);
//retrieve patient id from URL querystring if any
let patientId = urlParams.get('patient');
console.log("patient id from url query string: ", patientId);
console.log("authURL: ", authURL);
console.log("authURL: ", authURL);

fetch(authURL, {
// include cookies in request
Expand Down

0 comments on commit b190b4a

Please sign in to comment.