a fix in content_view_environemnt: the order of callbacks is important