Removed redundant closed function