testdriverai 4.2.23 → 4.2.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/system.js +11 -5
  2. package/package.json +1 -1
package/lib/system.js CHANGED
@@ -16,13 +16,19 @@ let primaryDisplay = null;
16
16
  // this is the only display we ever target, because fuck it
17
17
  // the vm only has one and most people only have one
18
18
  const getPrimaryDisplay = async () => {
19
- // calculate scaling resolution
20
- let graphics = await si.graphics();
21
- let primaryDisplay = graphics.displays.find(
22
- (display) => display.main == true,
23
- );
19
+
20
+ if (!primaryDisplay) {
24
21
 
22
+ // calculate scaling resolution
23
+ let graphics = await si.graphics();
24
+ primaryDisplay = graphics.displays.find(
25
+ (display) => display.main == true,
26
+ );
27
+
28
+ }
29
+
25
30
  return primaryDisplay;
31
+
26
32
  };
27
33
 
28
34
  const getSystemInformationOsInfo = async () => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "testdriverai",
3
- "version": "4.2.23",
3
+ "version": "4.2.24",
4
4
  "description": "Next generation autonomous AI agent for end-to-end testing of web & desktop",
5
5
  "main": "index.js",
6
6
  "bin": {