This sounds more like a question of sportsmanship and the play-style of people you choose to play with rather than an actual rules question.
Yes, discarding is the last thing you do on your turn; when you make a meld you do so during your turn before discarding your card.
However, as long as the next player has not taken a turn, or provided any additional information, there is no reason to not allow a player to still play their meld.
It is unclear from your question why your opponent did not lay down the meld first. In Phase 10 there is never a reason to hold onto a meld that you could play instead. So is it that he didn’t notice that he didn’t have the meld until just after he discarded? Or he didn’t understand that melding should happen before discarding? Or was it just his style of laying down all his cards to lay down the discard right before the meld; just messing around? In any of these cases, I and the people I play games with would consider it poor sportsmanship to tell the person that they cannot play their meld because technically the discard card hit the table before the meld cards did. What matters is that they all happened on the same turn.
This could be different in other similar games where there is sometimes a reason to not play a meld when you can. In that case a person could choose to not play a meld, but then change their mind at last second after they discard a card; perhaps because something in their opponent's face told them that the card they chose to discard means that this turn was their last chance to meld. But in Phase 10, laying down your meld as soon as you have the required cards is an automatic decision; there is no skill or strategy in deciding when to meld.