@@ -24,13 +24,13 @@ |
||
24 | 24 | // ->addField('name', TypeMap::TYPE_STRING, ['description' => 'The name of the character']) |
25 | 25 | // ; |
26 | 26 | $config->addFields([ |
27 | - 'id' => ['type' => TypeMap::TYPE_ID, |
|
28 | - 'required' => true, |
|
29 | - 'description' => 'ID of the character'], |
|
30 | - 'name' => ['type' => TypeMap::TYPE_STRING, |
|
31 | - 'description' => 'The name of the character'], |
|
32 | - 'friends' => new ListType(['item' => new CharacterInterface()]) |
|
33 | - ]); |
|
27 | + 'id' => ['type' => TypeMap::TYPE_ID, |
|
28 | + 'required' => true, |
|
29 | + 'description' => 'ID of the character'], |
|
30 | + 'name' => ['type' => TypeMap::TYPE_STRING, |
|
31 | + 'description' => 'The name of the character'], |
|
32 | + 'friends' => new ListType(['item' => new CharacterInterface()]) |
|
33 | + ]); |
|
34 | 34 | } |
35 | 35 | |
36 | 36 | public function getDescription() |
@@ -40,7 +40,7 @@ |
||
40 | 40 | */ |
41 | 41 | public function addFields($fieldsArray) |
42 | 42 | { |
43 | - foreach($fieldsArray as $fieldName => $fieldConfig) { |
|
43 | + foreach ($fieldsArray as $fieldName => $fieldConfig) { |
|
44 | 44 | if (is_object($fieldConfig)) { |
45 | 45 | $this->addField($fieldName, $fieldConfig); |
46 | 46 | } else { |