From 336a807ee56de27adcb3f9d34b337300520568ac Mon Sep 17 00:00:00 2001 From: Taylor Otwell Date: Mon, 17 Oct 2016 08:28:14 -0500 Subject: [PATCH] remove extension --- src/Illuminate/Validation/Rules/NotIn.php | 30 ++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/src/Illuminate/Validation/Rules/NotIn.php b/src/Illuminate/Validation/Rules/NotIn.php index 7fb6574515ec..ed93bc897619 100644 --- a/src/Illuminate/Validation/Rules/NotIn.php +++ b/src/Illuminate/Validation/Rules/NotIn.php @@ -2,10 +2,38 @@ namespace Illuminate\Validation\Rules; -class NotIn extends In +class NotIn { /** * The name of the rule. */ protected $rule = 'not_in'; + + /** + * The accepted values. + * + * @var array + */ + protected $values; + + /** + * Create a new "not in" rule instance. + * + * @param array $values + * @return void + */ + public function __construct(array $values) + { + $this->values = $values; + } + + /** + * Convert the rule to a validation string. + * + * @return string + */ + public function __toString() + { + return $this->rule.':'.implode(',', $this->values); + } }