Skip to content

Commit

Permalink
Use path.resolve() instead
Browse files Browse the repository at this point in the history
  • Loading branch information
okuryu committed Dec 6, 2019
1 parent 1f0e59f commit 1f313c7
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions bin/gh-pages.js
Expand Up @@ -8,10 +8,7 @@ const addr = require('email-addresses');

function publish(config) {
return new Promise((resolve, reject) => {
let basePath = program.dist;
if (!program.dist.startsWith('/')) {
basePath = path.join(process.cwd(), program.dist);
}
const basePath = path.resolve(process.cwd(), program.dist);
ghpages.publish(basePath, config, err => {
if (err) {
return reject(err);
Expand Down

0 comments on commit 1f313c7

Please sign in to comment.