Skip to content

Commit 9a4216d

Browse files
committed
Merge branch 'hotfix/52'
Close #52 Fixes #51
2 parents dc82056 + 20a0e87 commit 9a4216d

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

CHANGELOG.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
All notable changes to this project will be documented in this file, in reverse chronological order by release.
44

5-
## 1.2.3 - TBD
5+
## 1.2.3 - 2016-10-11
66

77
### Added
88

@@ -23,6 +23,9 @@ All notable changes to this project will be documented in this file, in reverse
2323
- [#50](https://github.com/zfcampus/zf-apigility-documentation/pull/50) fixes
2424
escaping of field decriptions; previously, the template was improperly using
2525
`escapeTransformDescription()` instead of `agTransformDescription()`.
26+
- [#52](https://github.com/zfcampus/zf-apigility-documentation/pull/52) fixes
27+
output of fields when the `allows_only_fields_in_filter` parameter is present
28+
for an input filter.
2629

2730
## 1.2.2 - 2016-08-10
2831

src/ApiFactory.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -204,10 +204,12 @@ public function createService(Api $api, $serviceName)
204204
$fields = [];
205205
if (isset($this->config['zf-content-validation'][$serviceClassName])) {
206206
foreach ($this->config['zf-content-validation'][$serviceClassName] as $validatorKey => $validatorName) {
207-
foreach ($this->mapFields($this->config['input_filter_specs'][$validatorName]) as $fieldData) {
208-
$fields[$validatorKey][] = $this->getField($fieldData);
207+
if (isset($this->config['input_filter_specs'][$validatorName])) {
208+
foreach ($this->mapFields($this->config['input_filter_specs'][$validatorName]) as $fieldData) {
209+
$fields[$validatorKey][] = $this->getField($fieldData);
210+
}
211+
$hasFields = true;
209212
}
210-
$hasFields = true;
211213
}
212214
}
213215

0 commit comments

Comments
 (0)