Completed
Push — master ( 5895ce...415b34 )
by Thomas
08:36
created

ActivityActivityObjectJsonResponder   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
lcom 0
cbo 3
dl 0
loc 16
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A run() 0 6 1
1
<?php
2
namespace keeko\core\responder;
3
4
use keeko\framework\foundation\AbstractResponder;
5
use Symfony\Component\HttpFoundation\Request;
6
use Symfony\Component\HttpFoundation\JsonResponse;
7
use keeko\core\model\Activity;
8
9
/**
10
 * Automatically generated JsonResponder for Reads the relationship of activity to activity_object
11
 * 
12
 * @author gossi
13
 */
14
class ActivityActivityObjectJsonResponder extends AbstractResponder {
15
16
	/**
17
	 * Automatically generated run method
18
	 * 
19
	 * @param Request $request
20
	 * @param mixed $data
21
	 * @return JsonResponse
22
	 */
23
	public function run(Request $request, $data = null) {
24
		$serializer = Activity::getSerializer();
25
		$relationship = $serializer->activityObject();
0 ignored issues
show
Bug introduced by
The method activityObject() does not seem to exist on object<keeko\framework\m...delSerializerInterface>.

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
26
27
		return new JsonResponse($relationship->toArray());
28
	}
29
}
30