Implemented basic closing mechanism