I need to remove the error from a component once the input changes. It’s working with the code bellow, and I wonder if I could make this easier:
public function updated($field)
{
/** @var MessageBag $messageBag */
$messageBag = $this->errorBag;
$validationErrors = $messageBag->getMessages();
unset($validationErrors[$field]);
$this->errorBag = new MessageBag($validationErrors);
}