Skip to content

Commit e6fa60b

Browse files
committed
Step 17.5: Filter user profile
1 parent 7a50024 commit e6fa60b

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/pages/profile/profile.ts

+4-3
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,10 @@ export class ProfilePage implements OnInit {
2222
) {}
2323

2424
ngOnInit(): void {
25-
this.profile = Meteor.user().profile || {
26-
name: ''
27-
};
25+
this.profile = (({name = '', pictureId} = {}) => ({
26+
name,
27+
pictureId
28+
}))(Meteor.user().profile);
2829

2930
MeteorObservable.subscribe('user').subscribe(() => {
3031
let platform = this.platform.is('android') ? "android" :

0 commit comments

Comments
 (0)