If you connected up multiple outputs together, and some of them decided to produce a logic 1, and others a logic 0. They would electrically fight each other (a bit like a short circuit), potentially overloading the chip(s) and maybe even damaging them.
There are outputs called "tristate" or "open collector", which can solve this problem. Tristate can be switched off (disabled), so that things can share, often called databuses e.g. for memory.
Open collector means that the outputs can only pull things towards ground, so it does not matter if you connect multiple outputs of that type, together. But it needs a (usually single) pull up resistor.
You did the right thing. The OR gate is the way to go.