Made the on_message callback less strict.