`set_damage` item modifer doesn't work properly

I wrote two item modifers, one that changes the number of a given item and one that changes the current damage of a given item. They both read a number from a scoreboard named newobj from the fake player newobj.

The one that sets the number of a given item works perfectly (when used on an item like a stick or dye)

[
  {
    "function": "minecraft:set_count",
    "count": {
      "type": "minecraft:score",
      "target": {
        "type": "minecraft:fixed",
        "name": "newobj"
      },
      "score": "newobj"
    },
    "add": false
  }
]

The one that sets the damage of the item, doesn't work, all it does is remove the damage component from the item (when using an item like a shovel or carrot stick)

[
  {
    "function": "minecraft:set_damage",
    "damage": {
      "type": "minecraft:score",
      "target": {
        "type": "minecraft:fixed",
        "name": "newobj"
      },
      "score": "newobj"
    },
    "add": false
  }
]

I'm probably missing something stupid, but I can't figure it out for the life of me. Both of these were generated with Misode, btw.

Continue to help post