mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
If the deprecated NODE_REPL_HISTORY_FILE is set to default node history file path ($HOME/.node_repl_history) and the file doesn't exist, then node creates the file and then crashes when it tries to parse that file as JSON thinking that it's an older JSON formatted history file. This fixes that bug. This patch also prevents node repl from throwing if the old history file is empty or if $HOME/.node_repl_history is empty. Fixes: https://github.com/nodejs/node/issues/4102 PR-URL: https://github.com/nodejs/node/pull/4108 Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Internal Modules
The modules in lib/internal are intended for internal use in Node.js core only, and are not accessible with require() from user modules.
These are subject to change at any time. Reliance on these modules outside of core is not supported in any way.