Fix bug on close item when not yet created.