In Hydrogen peroxide, the oxidation number of oxygen is "-1" instead of "-2".
But it seems to me that, the oxygen atoms have '-2' as their oxidation number as each oxygen atom here is connected to a hydrogen atom and an oxygen atom.
So, what's actually happening here?