I am playing CK2 with my friends in the Byzantine Empire. He is the emperor while I picked a duke in the kingdom. When he got enough money, he then created the Kingdom of Greece and gave it to me. But now, even though I have Agnatic-Cognatic Primogeniture, and I have a son, my friend (the emperor) is the still the heir to my kingdom. What can I do to fix this?
EDIT: Any time I give away a title like a dutchy, I'm am the heir for title.