Pass origin domain

main
Bob Mottram 2021-09-10 23:08:04 +01:00
parent d7cbe93391
commit 0234b752ce
2 changed files with 11 additions and 4 deletions

View File

@ -696,12 +696,15 @@ if args.posts:
if not args.language:
args.language = 'en'
signingPrivateKeyPem = None
originDomain = None
if args.domain:
originDomain = args.domain
if args.secureMode:
signingPrivateKeyPem = getInstanceActorKey(baseDir, domain)
getPublicPostsOfPerson(baseDir, nickname, domain, False, True,
proxyType, args.port, httpPrefix, debug,
__version__, args.language,
signingPrivateKeyPem)
signingPrivateKeyPem, originDomain)
sys.exit()
if args.postDomains:
@ -887,12 +890,15 @@ if args.postsraw:
if not args.language:
args.language = 'en'
signingPrivateKeyPem = None
originDomain = None
if args.domain:
originDomain = args.domain
if args.secureMode:
signingPrivateKeyPem = getInstanceActorKey(baseDir, domain)
getPublicPostsOfPerson(baseDir, nickname, domain, False, False,
proxyType, args.port, httpPrefix, debug,
__version__, args.language,
signingPrivateKeyPem)
signingPrivateKeyPem, originDomain)
sys.exit()
if args.json:

View File

@ -3818,7 +3818,8 @@ def getPublicPostsOfPerson(baseDir: str, nickname: str, domain: str,
port: int, httpPrefix: str,
debug: bool, projectVersion: str,
systemLanguage: str,
signingPrivateKeyPem: str) -> None:
signingPrivateKeyPem: str,
originDomain: str) -> None:
""" This is really just for test purposes
"""
print('Starting new session for getting public posts')
@ -3869,7 +3870,7 @@ def getPublicPostsOfPerson(baseDir: str, nickname: str, domain: str,
_getPosts(session, personUrl, 30, maxMentions, maxEmoji,
maxAttachments, federationList,
personCache, raw, simple, debug,
projectVersion, httpPrefix, domain, systemLanguage,
projectVersion, httpPrefix, originDomain, systemLanguage,
signingPrivateKeyPem)