loop closing ok