Inflating layout minor mistake?

On page 500 the book says to write the following code in the PhotoAdapter’s onCreateViewHolder():

View view = inflater.inflate(R.layout.gallery_item, viewGroup, false);

Am I missing something or should you not inflate the layout you created on the previous page like so:

View view = inflater.inflate(R.layout.list_item_gallery, viewGroup, false);

You are correct. It should be list_item_gallery. I just found out about that error in the book myself a few days ago.

It’s added that to the errata post: Errata (3rd Edition)

Thanks, I just came on here to post about this but glad to see it’s already listed!