fix and add log
fix