@@ -12,13 +12,13 @@ final class {{ class }}
12
12
* Validate if creation is allowed
13
13
* @return bool
14
14
*/
15
- public static function canCreate( array $args, ?string $className = __CLASS__ ): bool
15
+ public static function canCreate( array $args ): bool
16
16
{
17
- $validator = Validator::make($args, [
17
+ $validator = Validator::make( $args, [
18
18
// 'title' => 'required|string|max:191',
19
19
]);
20
20
21
- self::isFails( $validator, $className );
21
+ self::isFails( $validator );
22
22
23
23
return true;
24
24
}
@@ -27,24 +27,15 @@ final class {{ class }}
27
27
* Validate if update is allowed
28
28
* @return bool
29
29
*/
30
- public static function canUpdate( array $args, ?string $className = __CLASS__ ): bool
30
+ public static function canUpdate( array $args ): bool
31
31
{
32
- $validator = Validator::make($args, [
33
- // 'id' => 'required|exists:users,id',
32
+ $validator = Validator::make( $args, [
33
+ // 'id' => 'required|exists:users,id',
34
34
// 'title' => 'required|string|max:191',
35
35
]);
36
36
37
- self::isFails( $validator, $className );
37
+ self::isFails( $validator );
38
38
39
39
return true;
40
40
}
41
-
42
- /**
43
- * Validate if delete is allowed
44
- * @return bool
45
- */
46
- public static function canDelete( array $args, ?string $className = __CLASS__ ): bool
47
- {
48
- return true;
49
- }
50
41
}
0 commit comments