EnderTurret / PatchedMod

A Minecraft mod that adds the ability for data/resource packs and mods to patch JSON files, allowing them to avoid the incompatibility of replacing files wholesale.
GNU Lesser General Public License v2.1
2 stars 0 forks source link

[wiki] Invalid example json #22

Closed Estecka closed 1 week ago

Estecka commented 1 week ago

The wiki on Dynamic Patching provides this example json, which is invalid:

"targets": [
  "namespace": [ "minecraft" ],
  "path": [
    {
      "pattern": "worldgen/biome/.*\\.json"
    }
  ]
]

targets uses square brackets (array), but is formatted as an object. Is it supposed to be an object itself, or an array of such objects ?

EnderTurret commented 1 week ago

It's supposed to be an array of Target objects. I likely forgot to add the braces when I originally wrote the wiki page and then never caught it when I proofread it. I've just now edited the page to fix it. (Also please let me know if you encounter any other such errors while reading any of the docs -- I rewrote pretty much all of them relatively recently and while I tried to make sure there aren't any errors, I could have missed some.)