The appeals must be upheld for the reasons stated. Given the outcome of the proceedings, respondent 2, whose application is unsuccessful, is liable for costs and compensation (see Art. 66 para. 1 and Art. 68 para. 2 of the Federal Supreme Court Act). The Canton of Aargau bears no court costs (Art. 66 para. 4 of the Federal Supreme Court Act). The Federal Supreme Court therefore rules: 1. Proceedings 6B_85/2026 and 6B_96/2026 are joined. 2. The appeals are upheld, the contested judgments set aside, and the matter remitted to the lower instance for a new decision.