If I received money for a dependent in 2021 but she is being claimed by someone else, will I have to pay back the money?

I claimed a child in 2020, so during 2021 I received the advanced child payments.  I made a mistake this year and accidentally made my child a dependent on both my taxes and the fathers.  The fathers went through but mine was rejected even though mine was filed first.  So because I received the money this year, I am wondering if I am suppose to pay back or what will happen?