mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-20 23:46:14 -04:00
Installed API infrastructure, getText works already
This commit is contained in:
parent
39b5f57d4e
commit
f45b7ce9ea
7 changed files with 672 additions and 5 deletions
|
@ -19,6 +19,7 @@
|
|||
*/
|
||||
|
||||
require("../db/Pad");
|
||||
var db = require("./DB").db;
|
||||
|
||||
/**
|
||||
* A Array with all known Pads
|
||||
|
@ -58,6 +59,13 @@ exports.getPad = function(id, callback)
|
|||
}
|
||||
});
|
||||
}
|
||||
|
||||
//globalPads[id].timestamp = new Date().getTime();
|
||||
}
|
||||
|
||||
//checks if a pad exists
|
||||
exports.doesPadExists = function(padId, callback)
|
||||
{
|
||||
db.get("pad:"+padId, function(err, value)
|
||||
{
|
||||
callback(err, value != null);
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue