Skip to content

Commit

Permalink
- move file into new after delivery
Browse files Browse the repository at this point in the history
  • Loading branch information
aredridel committed Aug 24, 2010
1 parent ecb2622 commit 953942f
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions lib/mailbox.js
Expand Up @@ -26,6 +26,15 @@ Maildir.prototype.appendMessage = function(callback) {
s.on('open', function(fd) {
callback(null, s)
})
s.on('close', function(fd) {
fs.rename(s.path, self.path + '/new/' + messageName,
function(err) {
if(err) throw(err)
self.emit('close')

})
// move file
})
}
return s
}
Expand Down

0 comments on commit 953942f

Please sign in to comment.