Ryanair aren't totally dependent on their handling agent (or the police) to let passengers into the terminal building at Stansted. The airside passes/id cards carried by Stansted based cabin crew and pilots will open the doors.
This flight was operated by Oporto based crew and they don't have the right cards to work the electronic locks. Either Swissport forgot this, was overwhelmed by the number of diverted flights, or have no contract with Ryanair for "out-of-normal-flight-times" work. I doubt if anyone will ever tell us which..