Error   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 5
dl 0
loc 14
rs 10
c 1
b 0
f 1
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A allowed() 0 6 1
1
<?php
2
3
namespace Resova\Models;
4
5
use Resova\Model;
6
7
/**
8
 * Class Error
9
 *
10
 * @codeCoverageIgnore
11
 * @package Resova\Models
12
 */
13
class Error extends Model
14
{
15
16
    /**
17
     * List of allowed fields
18
     *
19
     * @return array
20
     */
21
    public function allowed(): array
22
    {
23
        return [
24
            'type'              => 'string', // type of error returned. Can be: 'api_error', 'authentication_error', 'not_found_error', 'validation_error' or 'rate_limit_error'.
25
            'message'           => 'string', // A message providing more details about the error.
26
            'validation_failed' => 'string', // For validation errors this will provide details on what validation failed.
27
        ];
28
    }
29
}
30