I worked on a truly awful mess of a codebase. It was the kind of codebase through which many devs had passed, and many generations of best practices. One part was straight JavaScript. Another had some jquery. Another had backbone.js - the perpetrators were all former full time employees. The product had never launched.
I generally worked 8 hours and signed off promptly to work on my own projects. I did quality work. I viewed myself as a hired gun who was paid to do a job. In the end I was at the company longer than any of their actual full time employees (who left because they didn't like working on the crappy code or were stressed because of company politics) and was the only developer left to take the product to launch.
Employees and employers often think that contractors are vampires, and many are, but you'll find the good ones are practically immune to whatever skeletons you've got in the closet and will get the job done.