Skip to content

Commit

Permalink
Reimplement findPeopleWithId in an attempt to fix stored person ove…
Browse files Browse the repository at this point in the history
…rrides
  • Loading branch information
reivilibre committed Jan 21, 2025
1 parent a67686b commit a193e29
Showing 1 changed file with 23 additions and 2 deletions.
25 changes: 23 additions & 2 deletions src/Conference.ts
Original file line number Diff line number Diff line change
Expand Up @@ -875,10 +875,31 @@ export class Conference {
}

/**
* @deprecated This always returns `[]` and should be removed or fixed.
* Return a list of all people with the given person ID.
*
* TODO does not support interest rooms
*/
public async findPeopleWithId(personId: string): Promise<IPerson[]> {
return [];
let out: IPerson[] = [];

for (let auditorium of Object.values(this.auditoriums)) {
let audDef = auditorium.getDefinition();
for (let talk of audDef.talks.values()) {

Check failure on line 887 in src/Conference.ts

View workflow job for this annotation

GitHub Actions / Build JSONSchema, TypeScript and Web

Property 'talks' does not exist on type 'Promise<IAuditorium>'.
for (let person of talk.speakers) {
if (person.id === personId) {
out.push(person);
}
}
}

for (let person of audDef.extraPeople) {

Check failure on line 895 in src/Conference.ts

View workflow job for this annotation

GitHub Actions / Build JSONSchema, TypeScript and Web

Property 'extraPeople' does not exist on type 'Promise<IAuditorium>'.
if (person.id === personId) {
out.push(person);
}
}
}

return out;
}

/**
Expand Down

0 comments on commit a193e29

Please sign in to comment.