Skip to content

Commit

Permalink
Add Campfire.Room.transcript method.
Browse files Browse the repository at this point in the history
  • Loading branch information
tristandunn committed Jun 8, 2011
1 parent 13f53e5 commit 5674b82
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lib/campfire.js
Expand Up @@ -206,6 +206,14 @@ Campfire.Room.prototype.speak = function(text, callback) {
this.message(text, 'TextMessage', callback);
};

Campfire.Room.prototype.transcript = function(date, callback) {
if (date instanceof Date) {
this.get('/transcript/' + date.getFullYear() + '/' + date.getMonth() + '/' + date.getDate(), callback);
} else if (date instanceof Function) {
this.get('/transcript', date);
}
};

Campfire.Room.prototype.tweet = function(url, callback) {
this.message(url, 'TweetMessage', callback);
};
Expand Down

0 comments on commit 5674b82

Please sign in to comment.