Laravel 5.2 验证不同给出 'Method does not exist' 错误

Laravel 5.2 validation distinct gives 'Method does not exist' error

我正在尝试根据唯一 ID 验证数组。我正在尝试使用 Laravel 的独特方法。使用此方法时出现此错误:Method [validateDistinct] does not exist.

我通读了文档,发现 5.2master 文档有所不同。我正在使用 5.2.19 版本。查看 version 5.2 documentation there is a distinct rule but the master version 文档时没有此规则。

所以基本上我的问题是:如何在 Laravel 5.2 中使用不同的验证规则?或者我做错了什么?

您需要升级到 5.2.22 版本