Earlier quoted context omitted.
Wouldn't this allow MEGA to also get a copy of the key so they can decrypt your data?
Only if they had a copy of the original plaintext file.
This is just the reason, why sensitive data needs to be encrypted before deduplication.
OFF System is also one interesting approach to this problem: https://en.wikipedia.org/wiki/OFFSystem
These are more or less "funny" work-a-rounds to the actual problem.