Skip to content

Commit 5c2903c

Browse files
committed
formatting
1 parent 4768e94 commit 5c2903c

File tree

1 file changed

+30
-30
lines changed

1 file changed

+30
-30
lines changed

src/Illuminate/Support/ValidatedInput.php

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,36 @@ public function __construct(array $input)
2727
$this->input = $input;
2828
}
2929

30+
/**
31+
* Determine if the validated input has one or more keys.
32+
*
33+
* @param mixed $keys
34+
* @return bool
35+
*/
36+
public function has($keys)
37+
{
38+
$keys = is_array($keys) ? $keys : func_get_args();
39+
40+
foreach ($keys as $key) {
41+
if (! Arr::has($this->input, $key)) {
42+
return false;
43+
}
44+
}
45+
46+
return true;
47+
}
48+
49+
/**
50+
* Determine if the validated input is missing one or more keys.
51+
*
52+
* @param mixed $keys
53+
* @return bool
54+
*/
55+
public function missing($keys)
56+
{
57+
return ! $this->has($keys);
58+
}
59+
3060
/**
3161
* Get a subset containing the provided keys with values from the input data.
3262
*
@@ -100,36 +130,6 @@ public function all()
100130
return $this->input;
101131
}
102132

103-
/**
104-
* Determine if the validated input has one or more keys.
105-
*
106-
* @param mixed $keys
107-
* @return bool
108-
*/
109-
public function has($keys)
110-
{
111-
$keys = is_array($keys) ? $keys : func_get_args();
112-
113-
foreach ($keys as $key) {
114-
if (! Arr::has($this->input, $key)) {
115-
return false;
116-
}
117-
}
118-
119-
return true;
120-
}
121-
122-
/**
123-
* Determine if the validated input is missing one or more keys.
124-
*
125-
* @param mixed $keys
126-
* @return bool
127-
*/
128-
public function missing($keys)
129-
{
130-
return ! $this->has($keys);
131-
}
132-
133133
/**
134134
* Get the instance as an array.
135135
*

0 commit comments

Comments
 (0)