File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed
data-browser/src/handlers Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,9 @@ export function buildSideBarNewResourceHandler(store: Store) {
66 const parentSubject = resource . get ( urls . properties . parent ) ;
77
88 if ( ! isString ( parentSubject ) ) {
9- throw new Error ( "Resource doesn't have a parent" ) ;
9+ throw new Error (
10+ `Resource doesn't have a parent: ${ resource . getSubject ( ) } ` ,
11+ ) ;
1012 }
1113
1214 const parent = await store . getResourceAsync ( parentSubject ) ;
@@ -31,7 +33,9 @@ export function buildSideBarRemoveResourceHandler(store: Store) {
3133 const parentSubject = resource . get ( urls . properties . parent ) ;
3234
3335 if ( ! isString ( parentSubject ) ) {
34- throw new Error ( "Resource doesn't have a parent" ) ;
36+ throw new Error (
37+ `Resource doesn't have a parent: ${ resource . getSubject ( ) } ` ,
38+ ) ;
3539 }
3640
3741 const parent = await store . getResourceAsync ( parentSubject ) ;
Original file line number Diff line number Diff line change @@ -557,7 +557,7 @@ export class Store {
557557 setCookieAuthentication ( this . serverUrl , agent ) ;
558558
559559 this . webSockets . forEach ( ws => {
560- authenticate ( ws , this ) ;
560+ ws . readyState === ws . OPEN && authenticate ( ws , this ) ;
561561 } ) ;
562562
563563 this . resources . forEach ( r => {
You can’t perform that action at this time.
0 commit comments