Add the message receiving function