Completed
Push — master ( 3a3d03...a83dbd )
by mains
10s
created
php/DatabaseConnect.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,6 +40,6 @@
 block discarded – undo
40 40
 			 ) DEFAULT CHARSET=utf8";
41 41
   if(!$db->query($query))
42 42
   {
43
-    throw new Exception($db->error($mysqli));
43
+	throw new Exception($db->error($mysqli));
44 44
   }
45 45
 
Please login to merge, or discard this patch.
php/Requests/GetKarma.php 1 patch
Indentation   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -3,18 +3,18 @@
 block discarded – undo
3 3
 
4 4
 class GetKarma extends AbstractRequest {
5 5
 		
6
-    function getApiEndPoint()
7
-    {
8
-        return '/v2/users/karma';
9
-    }
10
-    function getPayload()
11
-    {
12
-        return array(
13
-        );
14
-    }
15
-    function getMethod()
16
-    {
17
-        return 'GET';
18
-    }
6
+	function getApiEndPoint()
7
+	{
8
+		return '/v2/users/karma';
9
+	}
10
+	function getPayload()
11
+	{
12
+		return array(
13
+		);
14
+	}
15
+	function getMethod()
16
+	{
17
+		return 'GET';
18
+	}
19 19
 }
20 20
 
Please login to merge, or discard this patch.
php/Requests/GetPostDetails.php 1 patch
Indentation   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -3,18 +3,18 @@
 block discarded – undo
3 3
 
4 4
 class GetPostDetails extends AbstractRequest {
5 5
 		
6
-    function getApiEndPoint()
7
-    {
8
-        return '/v2/posts/' . $_GET['postID'];
9
-    }
10
-    function getPayload()
11
-    {
12
-        return array(
13
-        );
14
-    }
15
-    function getMethod()
16
-    {
17
-        return 'GET';
18
-    }
6
+	function getApiEndPoint()
7
+	{
8
+		return '/v2/posts/' . $_GET['postID'];
9
+	}
10
+	function getPayload()
11
+	{
12
+		return array(
13
+		);
14
+	}
15
+	function getMethod()
16
+	{
17
+		return 'GET';
18
+	}
19 19
 }
20 20
 
Please login to merge, or discard this patch.
php/AccountData.php 1 patch
Indentation   +90 added lines, -90 removed lines patch added patch discarded remove patch
@@ -2,94 +2,94 @@
 block discarded – undo
2 2
 
3 3
 class AccountData
4 4
 {
5
-    /**
6
-     * @var string
7
-     */
8
-    public $accessToken;
9
-    /**
10
-     * @var string
11
-     */
12
-    public $expirationDate;
13
-    /**
14
-     * @var string
15
-     */
16
-    public $refreshToken;
17
-    /**
18
-     * @var string
19
-     */
20
-    public $distinctId;
21
-    /**
22
-     * @var string
23
-     */
24
-    public $deviceUid;
25
-    /**
26
-     * @return string
27
-     */
28
-    public function getAccessToken()
29
-    {
30
-        return $this->accessToken;
31
-    }
32
-    /**
33
-     * @param string $accessToken
34
-     */
35
-    public function setAccessToken(string $accessToken)
36
-    {
37
-        $this->accessToken = $accessToken;
38
-    }
39
-    /**
40
-     * @return string
41
-     */
42
-    public function getExpirationDate()
43
-    {
44
-        return $this->expirationDate;
45
-    }
46
-    /**
47
-     * @param string $expirationDate
48
-     */
49
-    public function setExpirationDate(string $expirationDate)
50
-    {
51
-        $this->expirationDate = $expirationDate;
52
-    }
53
-    /**
54
-     * @return string
55
-     */
56
-    public function getRefreshToken()
57
-    {
58
-        return $this->refreshToken;
59
-    }
60
-    /**
61
-     * @param string $refreshToken
62
-     */
63
-    public function setRefreshToken(string $refreshToken)
64
-    {
65
-        $this->refreshToken = $refreshToken;
66
-    }
67
-    /**
68
-     * @return string
69
-     */
70
-    public function getDistinctId()
71
-    {
72
-        return $this->distinctId;
73
-    }
74
-    /**
75
-     * @param string $distinctId
76
-     */
77
-    public function setDistinctId(string $distinctId)
78
-    {
79
-        $this->distinctId = $distinctId;
80
-    }
81
-    /**
82
-     * @return string
83
-     */
84
-    public function getDeviceUid()
85
-    {
86
-        return $this->deviceUid;
87
-    }
88
-    /**
89
-     * @param string $deviceUid
90
-     */
91
-    public function setDeviceUid(string $deviceUid)
92
-    {
93
-        $this->deviceUid = $deviceUid;
94
-    }
5
+	/**
6
+	 * @var string
7
+	 */
8
+	public $accessToken;
9
+	/**
10
+	 * @var string
11
+	 */
12
+	public $expirationDate;
13
+	/**
14
+	 * @var string
15
+	 */
16
+	public $refreshToken;
17
+	/**
18
+	 * @var string
19
+	 */
20
+	public $distinctId;
21
+	/**
22
+	 * @var string
23
+	 */
24
+	public $deviceUid;
25
+	/**
26
+	 * @return string
27
+	 */
28
+	public function getAccessToken()
29
+	{
30
+		return $this->accessToken;
31
+	}
32
+	/**
33
+	 * @param string $accessToken
34
+	 */
35
+	public function setAccessToken(string $accessToken)
36
+	{
37
+		$this->accessToken = $accessToken;
38
+	}
39
+	/**
40
+	 * @return string
41
+	 */
42
+	public function getExpirationDate()
43
+	{
44
+		return $this->expirationDate;
45
+	}
46
+	/**
47
+	 * @param string $expirationDate
48
+	 */
49
+	public function setExpirationDate(string $expirationDate)
50
+	{
51
+		$this->expirationDate = $expirationDate;
52
+	}
53
+	/**
54
+	 * @return string
55
+	 */
56
+	public function getRefreshToken()
57
+	{
58
+		return $this->refreshToken;
59
+	}
60
+	/**
61
+	 * @param string $refreshToken
62
+	 */
63
+	public function setRefreshToken(string $refreshToken)
64
+	{
65
+		$this->refreshToken = $refreshToken;
66
+	}
67
+	/**
68
+	 * @return string
69
+	 */
70
+	public function getDistinctId()
71
+	{
72
+		return $this->distinctId;
73
+	}
74
+	/**
75
+	 * @param string $distinctId
76
+	 */
77
+	public function setDistinctId(string $distinctId)
78
+	{
79
+		$this->distinctId = $distinctId;
80
+	}
81
+	/**
82
+	 * @return string
83
+	 */
84
+	public function getDeviceUid()
85
+	{
86
+		return $this->deviceUid;
87
+	}
88
+	/**
89
+	 * @param string $deviceUid
90
+	 */
91
+	public function setDeviceUid(string $deviceUid)
92
+	{
93
+		$this->deviceUid = $deviceUid;
94
+	}
95 95
 }
Please login to merge, or discard this patch.
php/Location.php 1 patch
Indentation   +47 added lines, -47 removed lines patch added patch discarded remove patch
@@ -2,51 +2,51 @@
 block discarded – undo
2 2
 
3 3
 class Location{
4 4
 
5
-    public $cityName;
6
-
7
-    public $lat;
8
-
9
-    public $lng;
10
-
11
-    public function getCityName()
12
-    {
13
-        return $this->cityName;
14
-    }
15
-
16
-    public function setCityName($cityName)
17
-    {
18
-        $this->cityName = $cityName;
19
-    }
20
-
21
-    public function getLat()
22
-    {
23
-        return $this->lat;
24
-    }
25
-
26
-    public function setLat($lat)
27
-    {
28
-        $this->lat = $lat;
29
-    }
30
-
31
-    public function getLng()
32
-    {
33
-        return $this->lng;
34
-    }
35
-
36
-    public function setLng($lng)
37
-    {
38
-        $this->lng = $lng;
39
-    }
40
-    public function toArray(){
41
-        return array(
42
-            "city" => $this->getCityName(),
43
-            "country" => 'DE',
44
-            "loc_accuracy" => '0.0',
45
-            "loc_coordinates" => array(
46
-                "lat" => $this->getLat(),
47
-                "lng" => $this->getLng(),
48
-            ),
49
-            "name" => $this->getCityName()
50
-        );
51
-    }
5
+	public $cityName;
6
+
7
+	public $lat;
8
+
9
+	public $lng;
10
+
11
+	public function getCityName()
12
+	{
13
+		return $this->cityName;
14
+	}
15
+
16
+	public function setCityName($cityName)
17
+	{
18
+		$this->cityName = $cityName;
19
+	}
20
+
21
+	public function getLat()
22
+	{
23
+		return $this->lat;
24
+	}
25
+
26
+	public function setLat($lat)
27
+	{
28
+		$this->lat = $lat;
29
+	}
30
+
31
+	public function getLng()
32
+	{
33
+		return $this->lng;
34
+	}
35
+
36
+	public function setLng($lng)
37
+	{
38
+		$this->lng = $lng;
39
+	}
40
+	public function toArray(){
41
+		return array(
42
+			"city" => $this->getCityName(),
43
+			"country" => 'DE',
44
+			"loc_accuracy" => '0.0',
45
+			"loc_coordinates" => array(
46
+				"lat" => $this->getLat(),
47
+				"lng" => $this->getLng(),
48
+			),
49
+			"name" => $this->getCityName()
50
+		);
51
+	}
52 52
 }
Please login to merge, or discard this patch.
php/Requests/UpdateLocation.php 1 patch
Indentation   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -3,37 +3,37 @@
 block discarded – undo
3 3
 
4 4
 class UpdateLocation extends AbstractRequest {
5 5
 		 /**
6
-     * @var Location
7
-     */
8
-    public $location;
9
-    /**
10
-     * @return Location
11
-     */
12
-    public function getLocation()
13
-    {
14
-        return $this->location;
15
-    }
16
-    /**
17
-     * @param Location $location
18
-     */
19
-    public function setLocation($location)
20
-    {
21
-        $this->location = $location;
22
-    }
6
+		  * @var Location
7
+		  */
8
+	public $location;
9
+	/**
10
+	 * @return Location
11
+	 */
12
+	public function getLocation()
13
+	{
14
+		return $this->location;
15
+	}
16
+	/**
17
+	 * @param Location $location
18
+	 */
19
+	public function setLocation($location)
20
+	{
21
+		$this->location = $location;
22
+	}
23 23
 		
24
-    function getApiEndPoint()
25
-    {
26
-        return '/v2/users/location';
27
-    }
28
-    function getPayload()
29
-    {
30
-        return array(
24
+	function getApiEndPoint()
25
+	{
26
+		return '/v2/users/location';
27
+	}
28
+	function getPayload()
29
+	{
30
+		return array(
31 31
 					"location" => $this->getLocation()->toArray(),
32
-        );
33
-    }
34
-    function getMethod()
35
-    {
36
-        return 'PUT';
37
-    }
32
+		);
33
+	}
34
+	function getMethod()
35
+	{
36
+		return 'PUT';
37
+	}
38 38
 }
39 39
 
Please login to merge, or discard this patch.
php/Requests/SetLocation.php 1 patch
Indentation   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -3,37 +3,37 @@
 block discarded – undo
3 3
 
4 4
 class UpdateLocation extends AbstractRequest {
5 5
 		 /**
6
-     * @var Location
7
-     */
8
-    public $location;
9
-    /**
10
-     * @return Location
11
-     */
12
-    public function getLocation()
13
-    {
14
-        return $this->location;
15
-    }
16
-    /**
17
-     * @param Location $location
18
-     */
19
-    public function setLocation($location)
20
-    {
21
-        $this->location = $location;
22
-    }
6
+		  * @var Location
7
+		  */
8
+	public $location;
9
+	/**
10
+	 * @return Location
11
+	 */
12
+	public function getLocation()
13
+	{
14
+		return $this->location;
15
+	}
16
+	/**
17
+	 * @param Location $location
18
+	 */
19
+	public function setLocation($location)
20
+	{
21
+		$this->location = $location;
22
+	}
23 23
 		
24
-    function getApiEndPoint()
25
-    {
26
-        return '/v2/users/location';
27
-    }
28
-    function getPayload()
29
-    {
30
-        return array(
24
+	function getApiEndPoint()
25
+	{
26
+		return '/v2/users/location';
27
+	}
28
+	function getPayload()
29
+	{
30
+		return array(
31 31
 					"location" => $this->getLocation()->toArray(),
32
-        );
33
-    }
34
-    function getMethod()
35
-    {
36
-        return 'PUT';
37
-    }
32
+		);
33
+	}
34
+	function getMethod()
35
+	{
36
+		return 'PUT';
37
+	}
38 38
 }
39 39
 
Please login to merge, or discard this patch.
php/Requests/SendJodel.php 1 patch
Indentation   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -1,26 +1,26 @@
 block discarded – undo
1 1
 <?php
2 2
 
3 3
 class SendJodel extends AbstractRequest {
4
-    public $location;
5
-    public $ancestor = "";
6
-    public $color = "";
4
+	public $location;
5
+	public $ancestor = "";
6
+	public $color = "";
7 7
     
8
-    function getApiEndPoint()
9
-    {
10
-        return '/v3/posts/';
11
-    }
8
+	function getApiEndPoint()
9
+	{
10
+		return '/v3/posts/';
11
+	}
12 12
 
13
-    function getPayload()
14
-    {
15
-        return array(
13
+	function getPayload()
14
+	{
15
+		return array(
16 16
 			"ancestor" => $this->ancestor,
17 17
 			"color" => $this->color,
18
-            "location" => $this->location->toArray(),
19
-            "message" => $_POST['message'],
20
-        );
21
-    }
22
-    function getMethod()
23
-    {
24
-        return 'POST';
25
-    }
18
+			"location" => $this->location->toArray(),
19
+			"message" => $_POST['message'],
20
+		);
21
+	}
22
+	function getMethod()
23
+	{
24
+		return 'POST';
25
+	}
26 26
 }
Please login to merge, or discard this patch.
php/Requests/GetPosts.php 1 patch
Indentation   +44 added lines, -44 removed lines patch added patch discarded remove patch
@@ -4,25 +4,25 @@  discard block
 block discarded – undo
4 4
 {
5 5
 	public $lastPostId;
6 6
 
7
-    /**
8
-     * @var Location
9
-     */
10
-    public $location;
11
-    public $url;
7
+	/**
8
+	 * @var Location
9
+	 */
10
+	public $location;
11
+	public $url;
12 12
 
13 13
         
14
-    function setUrl ($url)
15
-    {
16
-            $this->url = $url;
17
-    }
14
+	function setUrl ($url)
15
+	{
16
+			$this->url = $url;
17
+	}
18 18
     
19
-    function getUrl ()
20
-    {
21
-        return $this->url;
22
-    }
19
+	function getUrl ()
20
+	{
21
+		return $this->url;
22
+	}
23 23
 		
24
-    function setLastPostId ($lastPostId)
25
-    {
24
+	function setLastPostId ($lastPostId)
25
+	{
26 26
 			$this->lastPostId = $lastPostId;
27 27
 	}
28 28
 	
@@ -31,38 +31,38 @@  discard block
 block discarded – undo
31 31
 		return $this->lastPostId;
32 32
 	}
33 33
     
34
-    function getApiEndPoint()
35
-    {
36
-        $apiEndPoint = $this->getUrl();
34
+	function getApiEndPoint()
35
+	{
36
+		$apiEndPoint = $this->getUrl();
37 37
 
38
-        if ($this->getLastPostId() != "") {
38
+		if ($this->getLastPostId() != "") {
39 39
 			$apiEndPoint = $this->getUrl() . '?after=' . $this->getLastPostId();
40 40
 		}
41
-        return $apiEndPoint;
42
-    }
43
-    function getPayload()
44
-    {
45
-        if($this->version == 'v3')
46
-        {
47
-            $this->location = new Location();
48
-            $this->location->setLat(52.520006);
49
-            $this->location->setLng(13.404954);
50
-            $this->location->setCityName('Berlin');
41
+		return $apiEndPoint;
42
+	}
43
+	function getPayload()
44
+	{
45
+		if($this->version == 'v3')
46
+		{
47
+			$this->location = new Location();
48
+			$this->location->setLat(52.520006);
49
+			$this->location->setLng(13.404954);
50
+			$this->location->setCityName('Berlin');
51 51
 
52 52
 
53
-            return array(
54
-                "location" => $this->location->toArray(),
55
-                "stickies" => 'false',
56
-            );
57
-        }
58
-        else
59
-        {
60
-            return array(
61
-            );
62
-        }
63
-    }
64
-    function getMethod()
65
-    {
66
-        return 'GET';
67
-    }
53
+			return array(
54
+				"location" => $this->location->toArray(),
55
+				"stickies" => 'false',
56
+			);
57
+		}
58
+		else
59
+		{
60
+			return array(
61
+			);
62
+		}
63
+	}
64
+	function getMethod()
65
+	{
66
+		return 'GET';
67
+	}
68 68
 }
Please login to merge, or discard this patch.