fixed logger onstart callback timing