Tankōbon / main/db/people-repository / PeopleRepository
Class: PeopleRepository
Defined in: main/db/people-repository.ts:22
Persists people (writers, artists…) once each, shared by every book that credits them. A person is identified by first and last name, case-insensitively: two different authors with the same name would be merged, which a personal library can live with.
Constructors
Constructor
new PeopleRepository(
db):PeopleRepository
Defined in: main/db/people-repository.ts:23
Parameters
db
DatabaseSync
Returns
PeopleRepository
Methods
findOrCreate()
findOrCreate(
name):Person
Defined in: main/db/people-repository.ts:26
The person with this name, created if it doesn't exist yet. Names are trimmed first.