last_message: refactor abstract out common things