Fixed the bug of Closing Project.