Code Duplication    Length = 8-8 lines in 2 locations

src/Surfnet/StepupGateway/GatewayBundle/Pdp/Dto/Response.php 2 locations

@@ 160-167 (lines=8) @@
157
        if (isset($responseData['PolicyIdentifier'])) {
158
            $response->policyIdentifier = new PolicyIdentifier;
159
160
            if (isset($responseData['PolicyIdentifier']['PolicySetIdReference'])) {
161
                foreach ($responseData['PolicyIdentifier']['PolicySetIdReference'] as $policySetIdReferenceData) {
162
                    $policySetIdReference                               = new PolicySetIdReference;
163
                    $policySetIdReference->version                      = $policySetIdReferenceData['Version'];
164
                    $policySetIdReference->id                           = $policySetIdReferenceData['Id'];
165
                    $response->policyIdentifier->policySetIdReference[] = $policySetIdReference;
166
                }
167
            }
168
169
            if (isset($responseData['PolicyIdentifier']['PolicyIdReference'])) {
170
                foreach ($responseData['PolicyIdentifier']['PolicyIdReference'] as $policyIdReferenceData) {
@@ 169-176 (lines=8) @@
166
                }
167
            }
168
169
            if (isset($responseData['PolicyIdentifier']['PolicyIdReference'])) {
170
                foreach ($responseData['PolicyIdentifier']['PolicyIdReference'] as $policyIdReferenceData) {
171
                    $policyIdReference                               = new PolicyIdReference;
172
                    $policyIdReference->version                      = $policyIdReferenceData['Version'];
173
                    $policyIdReference->id                           = $policyIdReferenceData['Id'];
174
                    $response->policyIdentifier->policyIdReference[] = $policyIdReference;
175
                }
176
            }
177
        }
178
179
        $response->decision = $responseData['Decision'];