Skip to content

Commit

Permalink
fixes checking display variables
Browse files Browse the repository at this point in the history
  • Loading branch information
khassel committed Jan 5, 2025
1 parent 037bda6 commit 18a1554
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions clientonly/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,11 @@
.then(function (configReturn) {
// check environment for DISPLAY or WAYLAND_DISPLAY
const elecParams = ["js/electron.js"];
if (process.env.WAYLAND_DISPLAY !== "") {
if (process.env.WAYLAND_DISPLAY) {
console.log(`Client: Using WAYLAND_DISPLAY=${process.env.WAYLAND_DISPLAY}`);
elecParams.push("--enable-features=UseOzonePlatform");
elecParams.push("--ozone-platform=wayland");
} else if (process.env.DISPLAY !== "") {
} else if (process.env.DISPLAY) {
console.log(`Client: Using DISPLAY=${process.env.DISPLAY}`);
} else {
fail("Error: Requires environment variable WAYLAND_DISPLAY or DISPLAY, none is provided.");
Expand Down
2 changes: 1 addition & 1 deletion tests/electron/helpers/global-setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ exports.startApplication = async (configFilename, systemDate = null, electronPar
process.env.mmTestMode = "true";

// check environment for DISPLAY or WAYLAND_DISPLAY
if (process.env.WAYLAND_DISPLAY !== "") {
if (process.env.WAYLAND_DISPLAY) {
electronParams.unshift("js/electron.js", "--enable-features=UseOzonePlatform", "--ozone-platform=wayland");
} else {
electronParams.unshift("js/electron.js");
Expand Down

0 comments on commit 18a1554

Please sign in to comment.