File tree 1 file changed +7
-0
lines changed
1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -69,6 +69,7 @@ function createWindow () {
69
69
} else if ( process . argv [ i ] == '--logoff' ) {
70
70
logoff = true ;
71
71
} else if ( process . argv [ i ] == '--launch' ) {
72
+ let found = false ;
72
73
if ( i + 1 < process . argv . length ) {
73
74
let activity = process . argv [ i + 1 ] ;
74
75
if ( activity . indexOf ( '&' ) != - 1 ) {
@@ -77,9 +78,15 @@ function createWindow () {
77
78
for ( var j = 0 ; j < activities . length ; j ++ ) {
78
79
if ( activities [ j ] . id == activity ) {
79
80
launch = 'file://' + app . getAppPath ( ) + '/' + activities [ j ] . directory + '/index.html?n=' + activities [ j ] . name + '&a=' + process . argv [ i + 1 ] ;
81
+ found = true ;
80
82
break ;
81
83
}
82
84
}
85
+ if ( ! found ) {
86
+ console . log ( 'Warning: Activity "' + process . argv [ i + 1 ] + '" not found' ) ;
87
+ }
88
+ } else {
89
+ console . log ( 'Warning: No activity to launch provided' ) ;
83
90
}
84
91
}
85
92
}
You can’t perform that action at this time.
0 commit comments