disconnect method for server