Cleaned up the js for showing the client popup