2022 Retained Earnings from an LLC

Our LLC had $9,000 in retained earnings from 2022 to 2023. We would have paid taxes on these earnings, so how do I account for distributing them in 2023 and not pay taxes twice on them?