Fix local-to-local user in public area
This commit is contained in:
parent
c0914af002
commit
1fcadef8d0
|
@ -69,12 +69,6 @@ module.exports = class Note extends ActivityPubObject {
|
|||
return cb(Errors.UnexpectedState('Invalid user ID for local user!'));
|
||||
}
|
||||
|
||||
if (Message.AddressFlavor.ActivityPub !== message.getAddressFlavor()) {
|
||||
return cb(
|
||||
Errors.Invalid('Cannot build note for non-ActivityPub addressed message')
|
||||
);
|
||||
}
|
||||
|
||||
const remoteActorAccount = message.getRemoteToUser();
|
||||
if (!remoteActorAccount && message.isPrivate()) {
|
||||
return cb(
|
||||
|
|
|
@ -63,7 +63,6 @@ exports.getModule = class ActivityPubScannerTosser extends MessageScanTossModule
|
|||
async.waterfall(
|
||||
[
|
||||
callback => {
|
||||
// Private or addressed to a single AP Actor:
|
||||
Note.fromLocalMessage(message, this._webServer(), (err, noteInfo) => {
|
||||
return callback(err, noteInfo);
|
||||
});
|
||||
|
@ -95,7 +94,8 @@ exports.getModule = class ActivityPubScannerTosser extends MessageScanTossModule
|
|||
//
|
||||
// Update the Note's addressing:
|
||||
// - Private:
|
||||
// to: sharedInboxEndpoints[0]
|
||||
// to: Directly to addressed-to Actor inbox
|
||||
//
|
||||
// - Public:
|
||||
// to: https://www.w3.org/ns/activitystreams#Public
|
||||
// ... and the message.getRemoteToUser() value *if*
|
||||
|
|
Loading…
Reference in New Issue