-
Notifications
You must be signed in to change notification settings - Fork 205
Open
Description
I read Japanese edition and found a mistake that is not related to a main topic
The below code is written in a book
inPhotos: (parent: any) =>
tags
.filter((tag) => tag.userID === parent.id)
.map((tag) => tag.photoID)
.map((photoID) => photos.find((p) => p.id === photoID))However correct code is below
inPhotos: (parent: any) =>
tags
// NOT parent.id BUT parent.githubLogin
.filter((tag) => tag.userID === parent.githubLogin)
.map((tag) => tag.photoID)
.map((photoID) => photos.find((p) => p.id === photoID))tag.userID is githubLogin ("gPlake") NOT id ("1")
Metadata
Metadata
Assignees
Labels
No labels