The problem is that Trump has been pushing for a UK visit for quite some time. Wanted a full state visit, carriage ride with the Queen etc etc. Demanded that May prevent any protests from taking place.

Rejecting him entirely came with it’s own risks. Sure looks like it would have been the better option now though.