Skip to content

Loading…

Hi! I fixed some code for you! #2

Merged
merged 2 commits into from

4 participants

@node-migrator-bot

Hi!

I am migrationBot!

Did you know that path.{exists,existsSync} was moved to fs.{exists,existsSync}, and that tty.setRawMode(mode) was moved to tty.ReadStream#setRawMode() (i.e. process.stdin.setRawMode()) in node v0.8.0? Read more @API changes between v0.6 and v0.8

I automatically made some changes I think will help you migrate your codebase to node v0.8.0, please review these changes and merge them if you feel they are useful, If they are not you can ignore this Pull Request.

Have a Nice Day!

--migrationBot

@liangzan
Owner

woah thanks!

@liangzan liangzan closed this
@liangzan liangzan reopened this
@liangzan liangzan merged commit 57a367d into liangzan:master
@blakmatrix

Dōitashimashite

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 3 additions and 3 deletions.
  1. +2 −2 lib/parser.js
  2. +1 −1 lib/process_manager.js
View
4 lib/parser.js
@@ -172,12 +172,12 @@ function envFileContent(cmdOptions) {
envFiles = cmdOptions.env.split(',');
for (var i = 0; i < envFiles.length; i++ ) {
filePath = path.normalize(envFiles[i]);
- if (path.existsSync(filePath)) {
+ if (fs.existsSync(filePath)) {
fileContent += fs.readFileSync(filePath, 'utf8');
fileContent += "\n";
}
}
- } else if (path.existsSync(parser.cmdWorkingDir(cmdOptions) + '/.env')) {
+ } else if (fs.existsSync(parser.cmdWorkingDir(cmdOptions) + '/.env')) {
filePath = parser.cmdWorkingDir(cmdOptions) + '/.env';
fileContent = fs.readFileSync(filePath, 'utf8');
}
View
2 lib/process_manager.js
@@ -237,7 +237,7 @@ function writePIDFile(pid, name) {
*/
function removePIDFile(name) {
var pidFilePath = pidDir + name + '.pid';
- path.exists(pidFilePath, function(exists) {
+ fs.exists(pidFilePath, function(exists) {
if (exists) {
fs.unlinkSync(pidFilePath);
}
Something went wrong with that request. Please try again.