Skip to content

cupertino-files / resolveAuthor

Function: resolveAuthor()

resolveAuthor(store, component, author): IwaObject

Defined in: src/tswp/comments.ts:124

Resolve the author a new comment should be attributed to.

Reuse comes first at every step: by identifier, then by name, then the document's existing author. Only a name that matches nobody creates a new archive — and that one is registered in the author list, or the apps show a comment whose commenter is not in the document's roster.

Parameters

store

ObjectStore

component

Component

author

string | bigint | undefined

Returns

IwaObject

MIT licensed. Independently made — not by Apple in California. Not affiliated with or endorsed by Apple Inc.