Completed
Branch newinternal (ffe884)
by Simon
04:07
created
includes/Exceptions/AccessDeniedException.php 2 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -58,6 +58,9 @@
 block discarded – undo
58 58
 		return $this->fetchTemplate("exception/access-denied.tpl");
59 59
 	}
60 60
 
61
+	/**
62
+	 * @param string $action
63
+	 */
61 64
 	private function getLogEntry($action, User $user, PdoDatabase $database)
62 65
 	{
63 66
 		$logs = LogSearchHelper::get($database)
Please login to merge, or discard this patch.
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -8,9 +8,7 @@
 block discarded – undo
8 8
 
9 9
 namespace Waca\Exceptions;
10 10
 
11
-use Waca\DataObjects\Log;
12 11
 use Waca\DataObjects\User;
13
-use Waca\Helpers\LogHelper;
14 12
 use Waca\Helpers\SearchHelpers\LogSearchHelper;
15 13
 use Waca\PdoDatabase;
16 14
 
Please login to merge, or discard this patch.
includes/Helpers/LogHelper.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
 	 * @param int         $requestId
38 38
 	 * @param PdoDatabase $db
39 39
 	 *
40
-	 * @return array
40
+	 * @return DataObject[]
41 41
 	 */
42 42
 	public static function getRequestLogsWithComments($requestId, PdoDatabase $db)
43 43
 	{
Please login to merge, or discard this patch.
includes/Helpers/SearchHelpers/SearchHelperBase.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
 	 *
40 40
 	 * @param PdoDatabase $database
41 41
 	 * @param string      $table
42
-	 * @param null        $order Order by clause, excluding ORDER BY.
42
+	 * @param string        $order Order by clause, excluding ORDER BY.
43 43
 	 */
44 44
 	protected function __construct(PdoDatabase $database, $table, $order = null)
45 45
 	{
Please login to merge, or discard this patch.
includes/Helpers/SearchHelpers/LogSearchHelper.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
 	 */
61 61
 	public function byUser($userId)
62 62
 	{
63
-		$this->whereClause .=' AND user = ?';
63
+		$this->whereClause .= ' AND user = ?';
64 64
 		$this->parameterList[] = $userId;
65 65
 
66 66
 		return $this;
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 	 */
76 76
 	public function byAction($action)
77 77
 	{
78
-		$this->whereClause .=' AND action = ?';
78
+		$this->whereClause .= ' AND action = ?';
79 79
 		$this->parameterList[] = $action;
80 80
 
81 81
 		return $this;
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
 	 */
91 91
 	public function byObjectType($objectType)
92 92
 	{
93
-		$this->whereClause .=' AND objecttype = ?';
93
+		$this->whereClause .= ' AND objecttype = ?';
94 94
 		$this->parameterList[] = $objectType;
95 95
 
96 96
 		return $this;
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
 	 */
106 106
 	public function byObjectId($objectId)
107 107
 	{
108
-		$this->whereClause .=' AND objectid = ?';
108
+		$this->whereClause .= ' AND objectid = ?';
109 109
 		$this->parameterList[] = $objectId;
110 110
 
111 111
 		return $this;
Please login to merge, or discard this patch.
includes/Helpers/SearchHelpers/RequestSearchHelper.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
 	 */
60 60
 	public function byIp($ipAddress)
61 61
 	{
62
-		$this->whereClause .=' AND (ip LIKE ? OR forwardedip LIKE ?)';
62
+		$this->whereClause .= ' AND (ip LIKE ? OR forwardedip LIKE ?)';
63 63
 		$this->parameterList[] = $ipAddress;
64 64
 		$this->parameterList[] = '%' . trim($ipAddress, '%') . '%';
65 65
 
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 	 */
76 76
 	public function byEmailAddress($emailAddress)
77 77
 	{
78
-		$this->whereClause .=' AND email LIKE ?';
78
+		$this->whereClause .= ' AND email LIKE ?';
79 79
 		$this->parameterList[] = $emailAddress;
80 80
 
81 81
 		return $this;
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
 	 */
91 91
 	public function byName($name)
92 92
 	{
93
-		$this->whereClause .=' AND name LIKE ?';
93
+		$this->whereClause .= ' AND name LIKE ?';
94 94
 		$this->parameterList[] = $name;
95 95
 
96 96
 		return $this;
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
 	 */
106 106
 	public function excludingRequest($requestId)
107 107
 	{
108
-		$this->whereClause .=' AND id <> ?';
108
+		$this->whereClause .= ' AND id <> ?';
109 109
 		$this->parameterList[] = $requestId;
110 110
 
111 111
 		return $this;
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
 	 */
119 119
 	public function withConfirmedEmail()
120 120
 	{
121
-		$this->whereClause .=' AND emailconfirm = ?';
121
+		$this->whereClause .= ' AND emailconfirm = ?';
122 122
 		$this->parameterList[] = 'Confirmed';
123 123
 
124 124
 		return $this;
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
 	 */
134 134
 	public function excludingPurgedData(SiteConfiguration $configuration)
135 135
 	{
136
-		$this->whereClause .=' AND ip <> ? AND email <> ?';
136
+		$this->whereClause .= ' AND ip <> ? AND email <> ?';
137 137
 		$this->parameterList[] = $configuration->getDataClearIp();
138 138
 		$this->parameterList[] = $configuration->getDataClearEmail();
139 139
 
Please login to merge, or discard this patch.
includes/Pages/PageLog.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -46,11 +46,11 @@
 block discarded – undo
46 46
 		$offset = ($page - 1) * $limit;
47 47
 
48 48
 		$logSearch = LogSearchHelper::get($database)->limit($limit, $offset);
49
-		if($filterUser !== null){
49
+		if ($filterUser !== null) {
50 50
 			$logSearch->byUser(User::getByUsername($filterUser, $database)->getId());
51 51
 		}
52 52
 
53
-		if($filterAction !== null){
53
+		if ($filterAction !== null) {
54 54
 			$logSearch->byAction($filterAction);
55 55
 		}
56 56
 
Please login to merge, or discard this patch.
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -46,11 +46,11 @@
 block discarded – undo
46 46
 		$offset = ($page - 1) * $limit;
47 47
 
48 48
 		$logSearch = LogSearchHelper::get($database)->limit($limit, $offset);
49
-		if($filterUser !== null){
49
+		if($filterUser !== null) {
50 50
 			$logSearch->byUser(User::getByUsername($filterUser, $database)->getId());
51 51
 		}
52 52
 
53
-		if($filterAction !== null){
53
+		if($filterAction !== null) {
54 54
 			$logSearch->byAction($filterAction);
55 55
 		}
56 56
 
Please login to merge, or discard this patch.
includes/Security/SecurityConfigurationFactory.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -125,7 +125,8 @@
 block discarded – undo
125 125
 	 * @category Security-Critical
126 126
 	 * @return SecurityConfiguration
127 127
 	 */
128
-	public function asNone() {
128
+	public function asNone()
129
+	{
129 130
 		$config = new SecurityConfiguration();
130 131
 
131 132
 		return $config;
Please login to merge, or discard this patch.