logic structure change + grunt work