Code Duplication    Length = 6-6 lines in 2 locations

api/v1/class.ShiftAPI.php 2 locations

@@ 244-249 (lines=6) @@
241
            }
242
            return $response->withJSON($dataTable->update($filter, $entity));
243
        }
244
        if(isset($entity['available']) && $entity['available'])
245
        {
246
            $entity['participant'] = $this->user->uid;
247
            $entity['status'] = 'filled';
248
            return $response->withJSON($dataTable->update($filter, $entity));
249
        }
250
        if(isset($entity['status']) && $entity['status'] === 'groupPending')
251
        {
252
            $entity['participant'] = $this->user->uid;
@@ 250-255 (lines=6) @@
247
            $entity['status'] = 'filled';
248
            return $response->withJSON($dataTable->update($filter, $entity));
249
        }
250
        if(isset($entity['status']) && $entity['status'] === 'groupPending')
251
        {
252
            $entity['participant'] = $this->user->uid;
253
            $entity['status'] = 'filled';
254
            return $response->withJSON($dataTable->update($filter, $entity));
255
        }
256
        print_r($entity); die();
257
    }
258