Yep, actually you are right on that - and the Supreme court ruled that when the appeal court allowed Begums appeal against the original commission decision against her, the appeal court was wrong on a number of counts including:
It erred in its approach to the appeal against the dismissal of Begum's application for
judicial review of the Home Secretary's refusal of leave to enter, making its own assessment of the requirements of
national security, despite having no relevant evidence before it or any relevant findings of fact.
Its approach failed to give the Home Secretary's assessment the respect it should have received.
It was mistaken in its finding that, when an individual's right to a fair hearing of an appeal came into conflict with the requirements of national security, the right to a fair hearing must prevail. If a vital public interest, such as public safety, makes it impossible for a case to be fairly heard, then it cannot ordinarily be heard. The appeal should therefore be
stayed until the appellant is in a position to play an effective part in it without public safety being compromised. In this case, it was not known how long it might be before that was possible.
So basically Begum has to prove she is not a threat to public safety before she can be allowed back into the UK - which of course is what all the BBC propaganda recently, painting her as a naïve kid with no agency or personal responsibility rather than a member of a terrorist cult, is all about.