Modify buffer, add console log