Read only access works

This commit is contained in:
Peter 'Pita' Martischka 2011-07-08 18:33:01 +01:00
parent 1c1e035bf1
commit 93ccbaef3a
3 changed files with 82 additions and 10 deletions

View file

@ -60,6 +60,15 @@ exports.getReadOnlyId = function (padId, callback)
})
}
/**
* returns a the padId for a read only id
* @param {String} readOnlyId read only id
*/
exports.getPadId = function(readOnlyId, callback)
{
db.get("readonly2pad:" + readOnlyId, callback);
}
/**
* Generates a random String with the given length. Is needed to generate the read only ids
*/