Some refugees left their country in tragic and dramatic circumstances. I am thinking of Iraq, Egypt, Libya and even Syria, where the situation has been absolutely horrible. Elsewhere, there were examples of enlightened despots in Morocco and elsewhere.
Despite this appearance of openness, I can tell you that in the 1960s in Morocco, the minister of Islamic affairs strongly promoted Islam and converting Jewish minors who were kidnapped from practically everywhere. Officially, measures were in place, but in reality things worked differently.
Gradually, it became difficult to obtain a passport, kidnappings took place and there were attacks on the public in certain places. Examples like these undermined the people's trust and dashed their hopes of having a future in a given country. So they left secretly. I would suggest that there are two different scenarios, but that in fact, they each result in identical conditions.