He will not get 45m. He will get 41.77m. The contract was stated as 45m so that when the 3.23m was taken off for signing mid-season, he would have the 6.96m contract that they negotiated and agreed on. That is why Nylander's compensation in the first year was set up as primarily salary. So that a portion of it would be immediately deleted.
When people say that he was "made whole", it means that they paid him the contract they agreed upon (6.96m x 6) instead of the ridiculous idea of trying to charge him millions for the negotiation stretching mid-season.
When you look at the cap page for 2018-2019:
Toronto Maple Leafs Daily Cap Tracker - CapFriendly - NHL Salary Caps
It shows what he actually made. 6.96m. The difference between the "cap hit" and "accumulated hit" is the portion of that 45m that was never meant to be earned. The only purpose of it was to be removed to create the desired cap hit.
His cap hit was 6.96m for all 6 seasons he was signed through.