Skip to content

Commit

Permalink
add version reader
Browse files Browse the repository at this point in the history
  • Loading branch information
inukshuk committed Aug 18, 2014
1 parent 001db8e commit 2f6523e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/message.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,13 @@ Object.defineProperties(Message.prototype, {
}
},

version: {
get: function () {
if (!this.res) return undefined;
return parseInt(this.headers['last-modified-version'], 10);
}
},

/**
* The response's HTTP status code.
*
Expand Down

0 comments on commit 2f6523e

Please sign in to comment.