You be the judge

A couple was in the divorce court arguing as to who should get custody of their only child. It seemed tht the judge was about to give custody to the wife , so as a last ditch effort he got up and said

"Your honor, Let me ask you a simple question. I go to a candy machine. I put in my quarter and the candy comes out. Does the candy belong to the machine or to me who put in the quarter in the first place. ???

you be the judge???