Skip to content

Commit 53c1fa8

Browse files
comments
1 parent bfcb473 commit 53c1fa8

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

app/common/renderer/actions/Session.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -226,8 +226,14 @@ export function newSession(originalCaps, attachSessId = null) {
226226
let sessionCaps = prefixedCaps ? getCapsObject(prefixedCaps) : {};
227227
sessionCaps = addCustomCaps(sessionCaps);
228228
let host, port, username, accessKey, https, path, headers;
229+
/**
230+
* To register a new session vendor:
231+
* - Implement a new class inherited from VendorBase in app/common/renderer/lib/vendor/<vendor_name>.js
232+
* - Add the newly created class to the VENDOR_MAP defined in app/common/renderer/lib/vendor/map.js
233+
*/
229234
const VendorClass = VENDOR_MAP[session.serverType];
230235
if (VendorClass) {
236+
log.info(`Using ${VendorClass.name}`);
231237
try {
232238
({host, port, username, accessKey, https, path, headers} = await new VendorClass(
233239
session.server,
@@ -236,6 +242,10 @@ export function newSession(originalCaps, attachSessId = null) {
236242
showError(e);
237243
return false;
238244
}
245+
} else {
246+
log.info(
247+
`No vendor mapping is defined for the server type '${session.serverType}'. Using defaults`
248+
);
239249
}
240250

241251
// if the server path is '' (or any other kind of falsy) set it to default

0 commit comments

Comments
 (0)