Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/rewire.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorsuisho <suisho000000@gmail.com>2013-03-01 21:05:44 +0400
committersuisho <suisho000000@gmail.com>2013-03-01 21:05:44 +0400
commit54e61d8a19093c3bddf170a7b01ce8e0edce63aa (patch)
tree320c31677c8057f3796743b3c3f7bdd282928d2a /lib
parent6d84a780db61a2b80c20d53adddc9887c2300874 (diff)
support module that without last empty line
Diffstat (limited to 'lib')
-rw-r--r--lib/rewire.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/rewire.js b/lib/rewire.js
index 3556533..bb7c176 100644
--- a/lib/rewire.js
+++ b/lib/rewire.js
@@ -37,7 +37,8 @@ function internalRewire(parentModulePath, targetPath) {
prelude = getImportGlobalsSrc();
// We append our special setter and getter.
- appendix = "module.exports.__set__ = " + __set__.toString() + "; ";
+ appendix = "\n";
+ appendix += "module.exports.__set__ = " + __set__.toString() + "; ";
appendix += "module.exports.__get__ = " + __get__.toString() + "; ";
// Check if the module uses the strict mode.