gtg092x / node-wp-cli

Node JS Wrapper for the Wordpress CLI
MIT License
40 stars 14 forks source link

wp core install: title containing spaces gets escaped #10

Open sjoerdlo opened 8 years ago

sjoerdlo commented 8 years ago
WP.core.install({"url":"http://localhost/mysite", "title":"site name", "admin_user":admin_user, "admin_password":admin_password, "admin_email":admin_email}, function(err, result) { });

After install the title will show as: site\ name

sjoerdlo commented 8 years ago

escapeshell in utils.js seems to be the cause.

When replacing it with this escapeshellarg function: http://phpjs.org/functions/escapeshellarg/ it seems to work.

peterjohnhunt commented 7 years ago

@sjoerdlo: I've experienced this issue when using WP.core.download as well, which will then create a new folder called site\ name.

Have you already submitted a PR?