Then, may be you deserved to win because his formation is not the best to beat 4-4-2 diamond (unless he made an effort to change it during the match). Both formations appear to cancel each other as given that his quality is better than you, you had 2 more player in defensive positions (as compared to 1 for him) to prevent his advantage of quality in attack, which explains why he could not get a goal. Still, you could have lost the match though as your formation was not the best either.
May be the orders for each team made the difference there. What mentality did you use?
The extra supporters could have contributed too, which reduced his possession, and hence he had less opportunities to build attacks (hence, the 1-0).