Removing a snap logs out my laptop

When removing a snap as soon as it is complete my desktop goes black and the login screen appears. Does any1 know a solution for this?

xubuntu 18.04.2 fully updated sont vaio laptop i7 quad 4gb mem snapd installed via terminal 2 days ago following the instructions on website.