Skip to content

Commit

Permalink
readline & zlib.js: named anonymous functions
Browse files Browse the repository at this point in the history
  • Loading branch information
antsmartian committed Jul 16, 2018
1 parent f9b739e commit d8ec3d9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/readline.js
Original file line number Diff line number Diff line change
Expand Up @@ -843,7 +843,7 @@ Interface.prototype._ttyWrite = function(s, key) {
if (this.listenerCount('SIGTSTP') > 0) {
this.emit('SIGTSTP');
} else {
process.once('SIGCONT', (function(self) {
process.once('SIGCONT', (function continueProcess(self) {
return function() {
// Don't raise events if stream has already been abandoned.
if (!self.paused) {
Expand Down
6 changes: 3 additions & 3 deletions lib/zlib.js
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ function processChunkSync(self, chunk, flushFlag) {
var chunkSize = self._chunkSize;

var error;
self.on('error', function(er) {
self.on('error', function onError(er) {
error = er;
});

Expand Down Expand Up @@ -691,11 +691,11 @@ inherits(Unzip, Zlib);

function createConvenienceMethod(ctor, sync) {
if (sync) {
return function(buffer, opts) {
return function syncBufferWrapper(buffer, opts) {
return zlibBufferSync(new ctor(opts), buffer);
};
} else {
return function(buffer, opts, callback) {
return function asyncBufferWrapper(buffer, opts, callback) {
if (typeof opts === 'function') {
callback = opts;
opts = {};
Expand Down

0 comments on commit d8ec3d9

Please sign in to comment.