Add amOwner() and amWriter(). Reject sendMessage() if we lack write access.

This commit is contained in:
Ian Gulliver
2015-12-29 12:00:35 -08:00
parent 415c6ad1fd
commit 3b3755f7f5
2 changed files with 31 additions and 5 deletions

View File

@@ -413,7 +413,7 @@ Cosmopolite.prototype.sendMessage = function(subject, message) {
(subject['readable_only_by'] || subject['writable_only_by'])) {
console.log(this.loggingPrefix_(),
'local subjects can\'t have ACLs:', subject);
reject();
reject(new Error('Local subject with ACL'));
return;
}