Add uuid to event

main
Bob Mottram 2020-08-21 22:42:49 +01:00
parent fede8b56d6
commit 5326583c18
2 changed files with 8 additions and 1 deletions

View File

@ -5732,6 +5732,11 @@ class PubServer(BaseHTTPRequestHandler):
if not fields.get('followersOnlyEvent'):
fields['followersOnlyEvent'] = False
if not fields.get('anonymousParticipationEnabled'):
anonymousParticipationEnabled = False
else:
anonymousParticipationEnabled = True
messageJson = \
createEventPost(self.server.baseDir,
nickname,
@ -5755,7 +5760,7 @@ class PubServer(BaseHTTPRequestHandler):
fields['endTime'],
fields['maximumAttendeeCapacity'],
fields['repliesModerationOption'],
fields['anonymousParticipationEnabled'],
anonymousParticipationEnabled,
fields['eventStatus'])
if messageJson:
if fields['schedulePost']:

View File

@ -854,6 +854,7 @@ def createPostBase(baseDir: str, nickname: str, domain: str, port: int,
mediaType, imageDescription, useBlurhash)
if eventUUID:
# add attributes for Mobilizon-type events
newPost['object']['uuid'] = eventUUID
if eventStatus:
newPost['object']['ical:status'] = eventStatus
if anonymousParticipationEnabled:
@ -916,6 +917,7 @@ def createPostBase(baseDir: str, nickname: str, domain: str, port: int,
mediaType, imageDescription, useBlurhash)
if eventUUID:
# add attributes for Mobilizon-type events
newPost['uuid'] = eventUUID
if eventStatus:
newPost['ical:status'] = eventStatus
if anonymousParticipationEnabled: