Without a doubt it has to do with what happened with Otto Warmbier. The U.S. student who was released from a North Korea jail in coma who later died.
I suspect Trump is trying to avoid similar events in the future. In addition there has been a lot more heated rhetoric between both sides as North Korea seem determined to create a missile capable of reaching U.S. shores. In the event military action is taken to prevent such a strike it's a good precaution to reduce putting Americans at risk by not allowing them travel there.