1. save scrap time
2. fix encoding bug