The legal advice you're getting is mostly wrong.
In California, income doesn't determine custody; all it determines is child support. If the court determines that Mom's the more appropriate parent, but you make more than she does, all the court needs to do to fix THAT is to order you to pay an appropriate amount of child support to her. See Burchard v. Garay (1986).
My family law experience is limited to what I learned in law school, but from what you wrote, you're making things worse.
Whenever there are child custody issues, you're always best to get an experienced family law attorney to help you out. By trying to get a breastfeeding mother kicked out so she'll "have no place to stay," you're not looking like the shining star to the court.
Do things the right way and after following your attorney's advice.