Refactoring+Fixed bug of actionlog

Refactoring+Fixed bug of actionlog