@@ 51-56 (lines=6) @@ | ||
48 | * there are not multiple instances of this |
|
49 | * input using the same action which is not likely. |
|
50 | */ |
|
51 | if (is_numeric($slug) && is_string($action)) { |
|
52 | $action = [ |
|
53 | 'slug' => $action, |
|
54 | 'action' => $action, |
|
55 | ]; |
|
56 | } |
|
57 | ||
58 | /* |
|
59 | * If the slug is NOT numeric and the action is a |
|
@@ 63-68 (lines=6) @@ | ||
60 | * string then use the slug as the slug and the |
|
61 | * action as the action. |
|
62 | */ |
|
63 | if (!is_numeric($slug) && is_string($action)) { |
|
64 | $action = [ |
|
65 | 'slug' => $slug, |
|
66 | 'action' => $action, |
|
67 | ]; |
|
68 | } |
|
69 | ||
70 | /* |
|
71 | * If the slug is not numeric and the action is an |
@@ 49-54 (lines=6) @@ | ||
46 | * is a string too then use the field as the |
|
47 | * type and the field as well. |
|
48 | */ |
|
49 | if (!is_numeric($slug) && is_string($slug) && is_string($field)) { |
|
50 | $field = [ |
|
51 | 'field' => $slug, |
|
52 | 'type' => $field, |
|
53 | ]; |
|
54 | } |
|
55 | ||
56 | /* |
|
57 | * If the field is an array and does not |
@@ 49-54 (lines=6) @@ | ||
46 | * there are not multiple instances of this |
|
47 | * input using the same action which is not likely. |
|
48 | */ |
|
49 | if (is_numeric($slug) && is_string($action)) { |
|
50 | $action = [ |
|
51 | 'slug' => $action, |
|
52 | 'action' => $action, |
|
53 | ]; |
|
54 | } |
|
55 | ||
56 | /* |
|
57 | * If the slug is NOT numeric and the action is a |
|
@@ 61-66 (lines=6) @@ | ||
58 | * string then use the slug as the slug and the |
|
59 | * action as the action. |
|
60 | */ |
|
61 | if (!is_numeric($slug) && is_string($action)) { |
|
62 | $action = [ |
|
63 | 'slug' => $slug, |
|
64 | 'action' => $action, |
|
65 | ]; |
|
66 | } |
|
67 | ||
68 | /* |
|
69 | * If the slug is not numeric and the action is an |
@@ 33-38 (lines=6) @@ | ||
30 | * there are not multiple instances of this |
|
31 | * input using the same view which is not likely. |
|
32 | */ |
|
33 | if (is_numeric($slug) && is_string($view)) { |
|
34 | $view = [ |
|
35 | 'slug' => $view, |
|
36 | 'view' => $view, |
|
37 | ]; |
|
38 | } |
|
39 | ||
40 | /* |
|
41 | * If the slug is NOT numeric and the view is a |
|
@@ 45-50 (lines=6) @@ | ||
42 | * string then use the slug as the slug and the |
|
43 | * view as the view. |
|
44 | */ |
|
45 | if (!is_numeric($slug) && is_string($view)) { |
|
46 | $view = [ |
|
47 | 'slug' => $slug, |
|
48 | 'view' => $view, |
|
49 | ]; |
|
50 | } |
|
51 | ||
52 | /* |
|
53 | * If the slug is not numeric and the view is an |