This repository was archived by the owner on Jan 4, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @uvalib/uvalib-account" ,
3
- "version" : " 0.1.20 " ,
3
+ "version" : " 0.1.21 " ,
4
4
"description" : " > TODO: description" ,
5
5
"author" : " Doug Chestnut <dougchestnut@gmail.com>" ,
6
6
"homepage" : " https://github.com/uvalib/web-components#readme" ,
Original file line number Diff line number Diff line change @@ -35,9 +35,12 @@ export default class UvalibAccountAuth extends HTMLElement {
35
35
this . dispatchEvent ( new CustomEvent ( 'uvalib-model-authenticated' , { bubbles :true , composed :true } ) ) ;
36
36
} . bind ( this ) )
37
37
. catch ( function ( error ) {
38
- console . error ( `Got an error code of ${ error . code } trying to login to Firebase. Reason: ${ error . message } ` ) ;
39
- // window.location.href = 'http://api.library.virginia.edu/fireauth/helloOccupancy.js?dest='+window.location.href;
40
- } )
38
+ console . error ( `Got an error code of ${ error . code } trying to login to Firebase. Reason: ${ error . message } ` ) ;
39
+ if ( this . userkey )
40
+ window . location . href = 'http://api.library.virginia.edu/fireauthkeyed/helloOccupancy.js?dest=' + window . location . href . replace ( / \? .* / , '' ) + '&userkey=' + this . userkey ;
41
+ else
42
+ window . location . href = 'http://api.library.virginia.edu/fireauth/helloOccupancy.js?dest=' + window . location . href ;
43
+ } . bind ( this ) )
41
44
}
42
45
43
46
}
You can’t perform that action at this time.
0 commit comments