Skip to content

Commit 2069b2b

Browse files
committed
fixed bug causing service script moving to fail when receiving non-stringy inputs
1 parent cd77ea2 commit 2069b2b

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
## {{ UNRELEASED_VERSION }} - [{{ UNRELEASED_DATE }}]({{ UNRELEASED_LINK }})
22

3+
* Fixed bug causing service script moving to fail when receiving non-stringy inputs
4+
35
## v3.23.23 - [January 14, 2025](https://github.com/lando/core/releases/tag/v3.23.23)
46

57
* Fixed bug causing service script loading collisions

builders/_lando.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ module.exports = {
4141
refreshCerts = false,
4242
remoteFiles = {},
4343
scripts = [],
44-
scriptsDir = '',
44+
scriptsDir = false,
4545
sport = '443',
4646
ssl = false,
4747
sslExpose = true,
@@ -68,7 +68,7 @@ module.exports = {
6868
}
6969

7070
// normalize scripts dir if needed
71-
if (!path.isAbsolute(scriptsDir)) scriptsDir = path.resolve(root, scriptsDir);
71+
if (typeof scriptsDir === 'string' && !path.isAbsolute(scriptsDir)) scriptsDir = path.resolve(root, scriptsDir);
7272

7373
// Get some basic locations
7474
const globalScriptsDir = path.join(userConfRoot, 'scripts');
@@ -83,7 +83,9 @@ module.exports = {
8383
if (fs.existsSync(confSrc)) require('../utils/move-config')(confSrc, confDest);
8484

8585
// ditto for service helpers
86-
if (fs.existsSync(scriptsDir)) require('../utils/move-config')(scriptsDir, serviceScriptsDir);
86+
if (!require('../utils/is-disabled')(scriptsDir) && typeof scriptsDir === 'string' && fs.existsSync(scriptsDir)) {
87+
require('../utils/move-config')(scriptsDir, serviceScriptsDir);
88+
}
8789

8890
// Handle Environment
8991
const environment = {

0 commit comments

Comments
 (0)