Scoreboards not working

So I have a command that says "scoreboard objectives add hard trigger" in my datapack in the load function. I have another command that says "scoreboard objectives add armor trigger". The game does not recognise the first command but does recognise the other. When I type in the command in game, it does load but it doesn't when I type /reload. Only 1 loads and vs code also doesn't recognise the other line. I know this because in the tick function, I have "scoreboard players enable @a hard" but it puts a squiggly yellow line under hard. It doesn't under armor however. I do not have later on in the load function to delete the hard objective. Please help.

Continue to help post