File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed
Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,11 @@ const Index = (props) => {
2727 } else {
2828 setBackOffice ( false ) ;
2929 }
30+ } else {
31+ // if no realm_access set, default to not using the back office
32+ setBackOffice ( false ) ;
3033 }
34+ console . log ( 'isBackOffice: ' + isBackOffice ) ;
3135 }
3236 useEffect ( ( ) => {
3337 FHIR . oauth2 . ready ( ) . then ( client => {
Original file line number Diff line number Diff line change @@ -25,7 +25,14 @@ const Launch = props => {
2525 localStorage . setItem ( 'clients' , JSON . stringify ( clients ) ) ;
2626 }
2727 }
28- const params = queryString . parse ( ( window . location . hash || '' ) . replace ( / \/ ? # \/ ? l a u n c h \? / , '' ) ) ;
28+
29+ let params = queryString . parse ( ( window . location . hash || '' ) . replace ( / \/ ? # \/ ? l a u n c h \? / , '' ) ) ;
30+
31+ // if no hash # value, pull the parameters out of the search
32+ if ( ! params . iss ) {
33+ params = queryString . parse ( ( window . location . search || '' ) . replace ( / \/ ? # ? \/ ? [ l a u n c h ] ? \? / , '' ) ) ;
34+ }
35+
2936 const iss = params . iss ;
3037 console . log ( 'iss: ' + iss ) ;
3138 const launch = params . launch ;
You can’t perform that action at this time.
0 commit comments