What is the first thing people tell you with a contract? You sign them in blood. I would suggest you make a habit of reading them before that point.
It's standard for literally every tech repair shop ever to have clauses regarding no responsibility for lost data. The key reason is they don't want to get caught holding a hot potato if the hdd is failing in a unit they diagnose, but the other reason is because the single best way to make sure all is well and good to avoid repeat repairs is to wipe the system.
Smaller shops can often heed verbal instruction or at least double check, but the big warranty centres are purely functional.
Sorry you got burned, hopefully you had a backup, and make sure to read your contract next time.