fix small defects and added popup