From 2950417f70d993f484e7102873f8dffe9a8df03a Mon Sep 17 00:00:00 2001 From: David Baker Date: Fri, 19 Feb 2016 15:35:36 +0000 Subject: [PATCH] Add docs to appease jslint --- lib/models/room.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lib/models/room.js b/lib/models/room.js index b91b1890b..bde1af4fa 100644 --- a/lib/models/room.js +++ b/lib/models/room.js @@ -940,6 +940,11 @@ Room.prototype.addReceipt = function(event, fake) { this.emit("Room.receipt", event, this); }; +/** + * Add a receipt event to the room. + * @param {MatrixEvent} event The m.receipt event. + * @param {Object} receipts The object to add receipts to + */ Room.prototype._addReceiptsToStructure = function(event, receipts) { var self = this; utils.keys(event.getContent()).forEach(function(eventId) { @@ -977,6 +982,11 @@ Room.prototype._addReceiptsToStructure = function(event, receipts) { }); }; +/** + * Build and return a map of receipts by event ID + * @param {Object} receipts A map of receipts + * @return {Object} Map of receipts by event ID + */ Room.prototype._buildReciptCache = function(receipts) { var receiptCacheByEventId = {}; utils.keys(receipts).forEach(function(receiptType) {