also support Arrive(Place)

This commit is contained in:
Mike Macgirvin 2023-09-09 08:16:05 +10:00
parent 64066522cf
commit ecb034abd9
2 changed files with 4 additions and 2 deletions

View file

@ -3278,7 +3278,9 @@ class Activity
$item['app'] = escape_tags($generator['name']);
}
$location = (new Place($act->get_property_obj('location')));
$location = ($act->type === 'Place')
? (new Place($act->obj))
: (new Place($act->get_property_obj('location')));
if ($location->getType() === 'Place') {
$item['location'] = $location->getName() ? escape_tags($location->getName()) : '';
// Look for something resembling latitude/longitude coordinates in the place name and set the

View file

@ -11,7 +11,7 @@ Supported activities:
- `Like()`, `Undo(Like)`.
- `Dislike()`,`Undo(Dislike)`.
- `Invite(Event)`, `Accept(Invite)`, `Reject(Invite)`, `TentativeAccept(Invite)`, `TentativeReject(Invite)`, `Update(Event)`, `Delete(Event)`.
- `Arrive(Note+location)`, `Leave(Note+location)`.
- `Arrive(Place|Note+location)`, `Leave(Place|Note+location)`.
- `Announce(Note)`, `Undo(Announce)`.
- `Update(Actor)`, `Move(Actor)`, `Delete(Actor)`.