[ Impact ]
When mounting an external location a script is used to get the current default app for a type, its return error is parsed by the dock to provide users a feedback, but the returned code is not valid in case of error.
[ Test case ]
Run: gjs -m /<email address hidden>/locationsWorker.js /foo/bar/baz echo $?
An error should be shown and the return code should be 15
Doing instead
gjs -m /<email address hidden>/locationsWorker.js $HOME echo $?
The file manager desktop-id should be printed and the script should return 0.
[ Regression Potential ]
Some locations may not have a default handler and so not being launched
[ Impact ]
When mounting an external location a script is used to get the current default app for a type, its return error is parsed by the dock to provide users a feedback, but the returned code is not valid in case of error.
[ Test case ]
Run: /locationsWorke r.js /foo/bar/baz
gjs -m /<email address hidden>
echo $?
An error should be shown and the return code should be 15
Doing instead
gjs -m /<email address hidden> /locationsWorke r.js $HOME
echo $?
The file manager desktop-id should be printed and the script should return 0.
[ Regression Potential ]
Some locations may not have a default handler and so not being launched