mirror of https://github.com/xwiki-labs/cryptpad
add notes re: logging and cold storage
This commit is contained in:
parent
0a1971cfee
commit
51fae45cce
|
@ -60,7 +60,7 @@ var handleTask = function (str, path, cb) {
|
||||||
}
|
}
|
||||||
}).nThen(function () {
|
}).nThen(function () {
|
||||||
// remove the task file...
|
// remove the task file...
|
||||||
Fs.unlink(path, function (err) {
|
Fs.unlink(path, function (err) { // FIXME deletion
|
||||||
if (err) { console.error(err); }
|
if (err) { console.error(err); }
|
||||||
cb();
|
cb();
|
||||||
});
|
});
|
||||||
|
|
|
@ -68,7 +68,7 @@ var closeChannel = function (env, channelName, cb) {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
var clearChannel = function (env, channelId, cb) {
|
var clearChannel = function (env, channelId, cb) { // FIXME deletion
|
||||||
var path = mkPath(env, channelId);
|
var path = mkPath(env, channelId);
|
||||||
getMetadataAtPath(env, path, function (e, metadata) {
|
getMetadataAtPath(env, path, function (e, metadata) {
|
||||||
if (e) { return cb(new Error(e)); }
|
if (e) { return cb(new Error(e)); }
|
||||||
|
@ -200,7 +200,7 @@ var checkPath = function (path, callback) {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
var removeChannel = function (env, channelName, cb) {
|
var removeChannel = function (env, channelName, cb) { // FIXME deletion
|
||||||
var filename = mkPath(env, channelName);
|
var filename = mkPath(env, channelName);
|
||||||
Fs.unlink(filename, cb);
|
Fs.unlink(filename, cb);
|
||||||
};
|
};
|
||||||
|
|
|
@ -67,6 +67,10 @@ var write = function (env, task, cb) {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// TODO implement a standard API for removing tasks
|
||||||
|
// currently they are deleted manually in 'expire-channels.js'
|
||||||
|
// var remove = function (env, id, cb) { };
|
||||||
|
|
||||||
Tasks.create = function (config, cb) {
|
Tasks.create = function (config, cb) {
|
||||||
var env = {
|
var env = {
|
||||||
root: config.taskPath || './tasks',
|
root: config.taskPath || './tasks',
|
||||||
|
|
Loading…
Reference in New Issue