a lawyer's second loyalty is to the court. (this is why you are given a lawyer in a trial... to protect the court)
a lawyer's third loyalty is to the judge. (hey, he has to work with this guy for the rest of his life)
and there is a few more before we get to you, the person that paid for the lawyers services.
Where did my keys go?