summaryrefslogtreecommitdiff
path: root/src/node/db/Pad.js
diff options
context:
space:
mode:
authorStefan <stefan@stefans-entwicklerecke.de>2015-03-15 14:51:27 +0100
committerStefan <stefan@stefans-entwicklerecke.de>2015-03-15 14:51:27 +0100
commitb9cdf4352b957b9127b6404af8b0078cb3309f0b (patch)
treedfc3eb947a19d229b8109a15bbf6b1e2c07c18cb /src/node/db/Pad.js
parentfb980031ba36f992d6f484266771d2fa87dfbda0 (diff)
parentc0260bcc40e93e9a47a20aada86a8513776f2e17 (diff)
downloadetherpad-lite-b9cdf4352b957b9127b6404af8b0078cb3309f0b.zip
Merge pull request #2552 from ether/release/1.5.2
Release/1.5.2
Diffstat (limited to 'src/node/db/Pad.js')
-rw-r--r--src/node/db/Pad.js15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/node/db/Pad.js b/src/node/db/Pad.js
index 2f5860f8..53847600 100644
--- a/src/node/db/Pad.js
+++ b/src/node/db/Pad.js
@@ -54,6 +54,21 @@ Pad.prototype.getHeadRevisionNumber = function getHeadRevisionNumber() {
return this.head;
};
+Pad.prototype.getSavedRevisionsNumber = function getSavedRevisionsNumber() {
+ return this.savedRevisions.length;
+};
+
+Pad.prototype.getSavedRevisionsList = function getSavedRevisionsList() {
+ var savedRev = new Array();
+ for(var rev in this.savedRevisions){
+ savedRev.push(this.savedRevisions[rev].revNum);
+ }
+ savedRev.sort(function(a, b) {
+ return a - b;
+ });
+ return savedRev;
+};
+
Pad.prototype.getPublicStatus = function getPublicStatus() {
return this.publicStatus;
};