removed duplicate code (#194)
This commit is contained in:
parent
fe3a209ac0
commit
115b8d9b70
|
@ -13,11 +13,9 @@ export class UserProfileService implements IUserProfileService {
|
||||||
|
|
||||||
constructor(serviceScope: ServiceScope) {
|
constructor(serviceScope: ServiceScope) {
|
||||||
serviceScope.whenFinished(() => {
|
serviceScope.whenFinished(() => {
|
||||||
serviceScope.whenFinished(() => {
|
|
||||||
this._spHttpClient = serviceScope.consume(SPHttpClient.serviceKey);
|
this._spHttpClient = serviceScope.consume(SPHttpClient.serviceKey);
|
||||||
this._pageContext = serviceScope.consume(PageContext.serviceKey);
|
this._pageContext = serviceScope.consume(PageContext.serviceKey);
|
||||||
this._currentWebUrl = this._pageContext.web.absoluteUrl;
|
this._currentWebUrl = this._pageContext.web.absoluteUrl;
|
||||||
});
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -80,4 +78,4 @@ export class UserProfileService implements IUserProfileService {
|
||||||
public getProfilePhoto(photoUrl: string) {
|
public getProfilePhoto(photoUrl: string) {
|
||||||
return `/_layouts/15/userphoto.aspx?size=M&url=${photoUrl}`;
|
return `/_layouts/15/userphoto.aspx?size=M&url=${photoUrl}`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue