Skip to content

Commit 9b95e0d

Browse files
Resolve build error
1 parent 4a0a567 commit 9b95e0d

File tree

3 files changed

+8
-16
lines changed

3 files changed

+8
-16
lines changed

package-lock.json

Lines changed: 4 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/services/PeopleSearchService.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -228,8 +228,8 @@ export default class SPPeopleSearchService {
228228
const userResults = values.map(element => {
229229
switch (element.EntityType) {
230230
case 'User':
231-
const accountName: string = element.Description || "";
232-
const email: string = element.EntityData?.Email || element.Description;
231+
const accountName: string = element.Description || "";
232+
const email: string = element.EntityData && element.EntityData.Email ? element.EntityData.Email : element.Description;
233233
return {
234234
id: element.Key,
235235
loginName: element.LoginName ? element.LoginName : element.Key,
@@ -241,7 +241,7 @@ export default class SPPeopleSearchService {
241241
optionalText: "" // anything
242242
} as IPeoplePickerUserItem;
243243
case 'SecGroup':
244-
const secondaryText = element.EntityData?.Email || element.ProviderName
244+
const secondaryText = element.EntityData && element.EntityData.Email ? element.EntityData.Email : element.ProviderName;
245245
return {
246246
id: element.Key,
247247
loginName: element.LoginName ? element.LoginName : element.Key,

src/webparts/controlsTest/ControlsTestWebPart.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import {
1010
} from '@microsoft/sp-property-pane';
1111

1212
import * as strings from 'ControlsTestWebPartStrings';
13-
import ControlsTest from './components/ControlsTest_SingleComponent';
13+
import ControlsTest from './components/ControlsTest';
1414
import { IControlsTestProps } from './components/IControlsTestProps';
1515
import { IControlsTestWebPartProps } from './IControlsTestWebPartProps';
1616

0 commit comments

Comments
 (0)