Your lawyer is wrong. The one and only one test the courts use to determine custody is: what is the best interest for the child. You should look for custody cases in your jurisdiction to see whether the judge likes sole custody or joint custody. Other things, such as income is totally irrelevant. One might argue that stable job and stable income really mean stability for the child. To a judge, they may not be. A parent with no income is not necessarily deprived of child custody because that is what child support is designed for. The other parent should support the child.