That's true of code developed in the absence of a working agreement. What GP meant, I assume, was that in _most_ cases, when you freelance or contract with a business with a MSA or other contract, that contract is going to specify that the work performed is WFH. Default ownership of copyright and code doesn't apply in this case.
But, if for some reason the agreement didn't specifically note the work performed as WFH then yes, the developer still owns the copyright to code they worked on. Where it gets muddy as hell is when you work with a team, some of whom may be other contractors and some of whom may be employees of the client.
But, if for some reason the agreement didn't specifically note the work performed as WFH then yes, the developer still owns the copyright to code they worked on. Where it gets muddy as hell is when you work with a team, some of whom may be other contractors and some of whom may be employees of the client.