Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
if (util.compareVersions(this.opts.platformVersion, '<', '12.2')) {
// this option does not work on 12.2 and above
this.opts.processArguments.args = ['-u', this._currentUrl];
}
} else if (this.opts.app || this.opts.bundleId) {
await this.configureApp();
}
this.logEvent('appConfigured');
// fail very early if the app doesn't actually exist
// or if bundle id doesn't point to an installed app
if (this.opts.app) {
await checkAppPresent(this.opts.app);
if (!this.opts.bundleId) {
this.opts.bundleId = await appUtils.extractBundleId(this.opts.app);
}
}
await this.runReset();
const memoizedLogInfo = _.memoize(function logInfo () {
log.info("'skipLogCapture' is set. Skipping starting logs such as crash, system, safari console and safari network.");
});
const startLogCapture = async () => {
if (this.opts.skipLogCapture) {
memoizedLogInfo();
return false;
}
const result = await this.startLogCapture();
if (result) {