The documentation provided in json.api.php uses the old resource_version name, instead of the correct resourceVersion. It confused me, and may confuse others.

I've provided a small patch to fix it. Pardon if it is already addressed.

CommentFileSizeAuthor
#5 3051908-5.patch1.32 KBRoensby
#2 3051908-2.patch1.31 KBRoensby

Comments

Roensby created an issue. See original summary.

Roensby’s picture

StatusFileSize
new1.31 KB

Patch to correct resource_version to resourceVersion in json.api.php

Roensby’s picture

gabesullice’s picture

Project: JSON:API » Drupal core
Version: 8.x-2.x-dev » 8.7.x-dev
Component: Code » jsonapi.module
Issue tags: -revision +API-First Initiative

Great catch, thanks @Roensby!

JSON:API 2.x is now in Drupal core. I've moved this issue there. Can you reroll your patch for core?

Roensby’s picture

StatusFileSize
new1.32 KB

Rerolled for core

idebr’s picture

Status: Active » Needs review
borisson_’s picture

Status: Needs review » Reviewed & tested by the community

Was already confirmed by @gabesullice that this is a correct thing to do. So setting to rtbc based on that.

wim leers’s picture

Gaahhh! Angry with myself that I missed this during review! Thanks 🙏

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Crediting @gabesullice for the issue management.

Committed and pushed cc7f7b1ecf to 8.8.x and 9590a5b337 to 8.7.x. Thanks!

  • alexpott committed cc7f7b1 on 8.8.x
    Issue #3051908 by Roensby, gabesullice: Documentation in json.api.php...

  • alexpott committed 9590a5b on 8.7.x
    Issue #3051908 by Roensby, gabesullice: Documentation in json.api.php...
gabesullice’s picture

Backported to JSON:API 8.x-2.x in contrib: https://git.drupalcode.org/project/jsonapi/commit/a6f230f

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.