Passed
Push — 17.1 ( 431f3f...4dae72 )
by Ralf
01:23 queued 12s
created
admin/inc/class.admin_wizard_export_users_csv.inc.php 3 patches
Indentation   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -18,20 +18,20 @@
 block discarded – undo
18 18
 		parent::__construct();
19 19
 
20 20
 		// Field mapping
21
-                $this->export_fields = array(
21
+				$this->export_fields = array(
22 22
 			'account_id'		=> lang('Account ID'),
23
-                        'account_lid'		=> lang('LoginID'),
24
-                        'account_firstname'	=> lang('First Name'),
25
-                        'account_lastname'	=> lang('Last Name'),
26
-                        'account_email'		=> lang('email'),
27
-                        'account_pwd'		=> lang('Password'),
28
-                        'account_status'	=> lang('Status'),
29
-                        'account_primary_group'	=> lang('Primary Group'),
30
-                        'account_groups'	=> lang('Groups'),
31
-                        'account_expires'	=> lang('Expires'),
32
-                        'account_lastlogin'	=> lang('Last login'),
33
-                        'account_lastpwd_change'=> lang('Last password change'),
34
-                );
23
+						'account_lid'		=> lang('LoginID'),
24
+						'account_firstname'	=> lang('First Name'),
25
+						'account_lastname'	=> lang('Last Name'),
26
+						'account_email'		=> lang('email'),
27
+						'account_pwd'		=> lang('Password'),
28
+						'account_status'	=> lang('Status'),
29
+						'account_primary_group'	=> lang('Primary Group'),
30
+						'account_groups'	=> lang('Groups'),
31
+						'account_expires'	=> lang('Expires'),
32
+						'account_lastlogin'	=> lang('Last login'),
33
+						'account_lastpwd_change'=> lang('Last password change'),
34
+				);
35 35
 
36 36
 		// Custom fields - not really used in admin...
37 37
 		unset($this->export_fields['customfields']);
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,7 +14,8 @@  discard block
 block discarded – undo
14 14
 
15 15
 class admin_wizard_export_users_csv extends importexport_wizard_basic_export_csv
16 16
 {
17
-	public function __construct() {
17
+	public function __construct()
18
+	{
18 19
 		parent::__construct();
19 20
 
20 21
 		// Field mapping
@@ -36,7 +37,8 @@  discard block
 block discarded – undo
36 37
 		// Custom fields - not really used in admin...
37 38
 		unset($this->export_fields['customfields']);
38 39
 		$custom = Api\Storage\Customfields::get('admin', true);
39
-		foreach($custom as $name => $data) {
40
+		foreach($custom as $name => $data)
41
+		{
40 42
 			$this->export_fields['#'.$name] = $data['label'];
41 43
 		}
42 44
 	}
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
 		// Custom fields - not really used in admin...
28 28
 		unset($this->export_fields['customfields']);
29 29
 		$custom = Api\Storage\Customfields::get('admin', true);
30
-		foreach($custom as $name => $data) {
30
+		foreach ($custom as $name => $data) {
31 31
 			$this->export_fields['#'.$name] = $data['label'];
32 32
 		}
33 33
 	}
Please login to merge, or discard this patch.
admin/inc/class.admin_egw_group_record.inc.php 2 patches
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -34,8 +34,8 @@  discard block
 block discarded – undo
34 34
 	 *
35 35
 	 * @param string $_identifier
36 36
 	 */
37
-	public function __construct( $_identifier='' ) {
38
-		if(is_array($_identifier)) {
37
+	public function __construct($_identifier = '') {
38
+		if (is_array($_identifier)) {
39 39
 			$this->identifier = $_identifier['account_id'];
40 40
 		} else {
41 41
 			$this->identifier = $_identifier;
@@ -89,9 +89,9 @@  discard block
 block discarded – undo
89 89
 	 * @todo add some checks
90 90
 	 * @return void
91 91
 	 */
92
-	public function set_record(array $_record){
92
+	public function set_record(array $_record) {
93 93
 		$this->group = $_record;
94
-		$this->group['account_members'] = $GLOBALS['egw']->accounts->members($this->group['account_id'],true);
94
+		$this->group['account_members'] = $GLOBALS['egw']->accounts->members($this->group['account_id'], true);
95 95
 	}
96 96
 
97 97
 	/**
@@ -118,8 +118,8 @@  discard block
 block discarded – undo
118 118
 	 *
119 119
 	 * @return string identifier
120 120
 	 */
121
-	public function save ( $_dst_identifier ) {
122
-		unset($_dst_identifier);	// not used, but require by function signature
121
+	public function save($_dst_identifier) {
122
+		unset($_dst_identifier); // not used, but require by function signature
123 123
 	}
124 124
 
125 125
 	/**
@@ -128,8 +128,8 @@  discard block
 block discarded – undo
128 128
 	 * @param string $_dst_identifier
129 129
 	 * @return string dst_identifier
130 130
 	 */
131
-	public function copy ( $_dst_identifier ) {
132
-		unset($_dst_identifier);	// not used, but require by function signature
131
+	public function copy($_dst_identifier) {
132
+		unset($_dst_identifier); // not used, but require by function signature
133 133
 	}
134 134
 
135 135
 	/**
@@ -139,15 +139,15 @@  discard block
 block discarded – undo
139 139
 	 * @param string $_dst_identifier
140 140
 	 * @return string dst_identifier
141 141
 	 */
142
-	public function move ( $_dst_identifier ) {
143
-		unset($_dst_identifier);	// not used, but require by function signature
142
+	public function move($_dst_identifier) {
143
+		unset($_dst_identifier); // not used, but require by function signature
144 144
 	}
145 145
 
146 146
 	/**
147 147
 	 * delets current record from backend
148 148
 	 *
149 149
 	 */
150
-	public function delete () {
150
+	public function delete() {
151 151
 
152 152
 	}
153 153
 
Please login to merge, or discard this patch.
Braces   +31 added lines, -15 removed lines patch added patch discarded remove patch
@@ -34,10 +34,14 @@  discard block
 block discarded – undo
34 34
 	 *
35 35
 	 * @param string $_identifier
36 36
 	 */
37
-	public function __construct( $_identifier='' ) {
38
-		if(is_array($_identifier)) {
37
+	public function __construct( $_identifier='' )
38
+	{
39
+		if(is_array($_identifier))
40
+		{
39 41
 			$this->identifier = $_identifier['account_id'];
40
-		} else {
42
+		}
43
+		else
44
+		{
41 45
 			$this->identifier = $_identifier;
42 46
 		}
43 47
 		$this->set_record($GLOBALS['egw']->accounts->read($this->identifier));
@@ -48,7 +52,8 @@  discard block
 block discarded – undo
48 52
 	 *
49 53
 	 * @param string $_attribute_name
50 54
 	 */
51
-	public function __get($_attribute_name) {
55
+	public function __get($_attribute_name)
56
+	{
52 57
 		return $this->group[$_attribute_name];
53 58
 	}
54 59
 
@@ -58,7 +63,8 @@  discard block
 block discarded – undo
58 63
 	 * @param string $_attribute_name
59 64
 	 * @param data $data
60 65
 	 */
61
-	public function __set($_attribute_name, $data) {
66
+	public function __set($_attribute_name, $data)
67
+	{
62 68
 		$this->group[$_attribute_name] = $data;
63 69
 	}
64 70
 
@@ -70,7 +76,8 @@  discard block
 block discarded – undo
70 76
 	 *
71 77
 	 * @return array complete record as associative array
72 78
 	 */
73
-	public function get_record_array() {
79
+	public function get_record_array()
80
+	{
74 81
 		return $this->group;
75 82
 	}
76 83
 
@@ -79,7 +86,8 @@  discard block
 block discarded – undo
79 86
 	 *
80 87
 	 *@return string title
81 88
 	 */
82
-	public function get_title() {
89
+	public function get_title()
90
+	{
83 91
 		return Api\Accounts::username($this->identifier);
84 92
 	}
85 93
 
@@ -89,7 +97,8 @@  discard block
 block discarded – undo
89 97
 	 * @todo add some checks
90 98
 	 * @return void
91 99
 	 */
92
-	public function set_record(array $_record){
100
+	public function set_record(array $_record)
101
+	{
93 102
 		$this->group = $_record;
94 103
 		$this->group['account_members'] = $GLOBALS['egw']->accounts->members($this->group['account_id'],true);
95 104
 	}
@@ -99,7 +108,8 @@  discard block
 block discarded – undo
99 108
 	 *
100 109
 	 * @return string identifier of current record
101 110
 	 */
102
-	public function get_identifier() {
111
+	public function get_identifier()
112
+	{
103 113
 		return $this->identifier;
104 114
 	}
105 115
 
@@ -109,7 +119,8 @@  discard block
 block discarded – undo
109 119
 	 *
110 120
 	 * @return string Full URL of an icon, or appname/icon_name
111 121
 	 */
112
-	public function get_icon() {
122
+	public function get_icon()
123
+	{
113 124
 		return 'group';
114 125
 	}
115 126
 
@@ -118,7 +129,8 @@  discard block
 block discarded – undo
118 129
 	 *
119 130
 	 * @return string identifier
120 131
 	 */
121
-	public function save ( $_dst_identifier ) {
132
+	public function save ( $_dst_identifier )
133
+	{
122 134
 		unset($_dst_identifier);	// not used, but require by function signature
123 135
 	}
124 136
 
@@ -128,7 +140,8 @@  discard block
 block discarded – undo
128 140
 	 * @param string $_dst_identifier
129 141
 	 * @return string dst_identifier
130 142
 	 */
131
-	public function copy ( $_dst_identifier ) {
143
+	public function copy ( $_dst_identifier )
144
+	{
132 145
 		unset($_dst_identifier);	// not used, but require by function signature
133 146
 	}
134 147
 
@@ -139,7 +152,8 @@  discard block
 block discarded – undo
139 152
 	 * @param string $_dst_identifier
140 153
 	 * @return string dst_identifier
141 154
 	 */
142
-	public function move ( $_dst_identifier ) {
155
+	public function move ( $_dst_identifier )
156
+	{
143 157
 		unset($_dst_identifier);	// not used, but require by function signature
144 158
 	}
145 159
 
@@ -147,7 +161,8 @@  discard block
 block discarded – undo
147 161
 	 * delets current record from backend
148 162
 	 *
149 163
 	 */
150
-	public function delete () {
164
+	public function delete ()
165
+	{
151 166
 
152 167
 	}
153 168
 
@@ -155,7 +170,8 @@  discard block
 block discarded – undo
155 170
 	 * destructor
156 171
 	 *
157 172
 	 */
158
-	public function __destruct() {
173
+	public function __destruct()
174
+	{
159 175
 		unset ($this->group);
160 176
 	}
161 177
 }
Please login to merge, or discard this patch.
admin/inc/class.admin_wizard_import_users_csv.inc.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@
 block discarded – undo
59 59
 	function wizard_step50(&$content, &$sel_options, &$readonlys, &$preserv)
60 60
 	{
61 61
 		$result = parent::wizard_step50($content, $sel_options, $readonlys, $preserv);
62
-		$content['msg'] .= "\n*" ;
62
+		$content['msg'] .= "\n*";
63 63
 		
64 64
 		return $result;
65 65
 	}
Please login to merge, or discard this patch.
admin/phpinfo.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@
 block discarded – undo
15 15
 );
16 16
 include('../header.inc.php');
17 17
 
18
-if ($GLOBALS['egw']->acl->check('info_access',1,'admin'))
18
+if ($GLOBALS['egw']->acl->check('info_access', 1, 'admin'))
19 19
 {
20 20
 	$GLOBALS['egw']->redirect_link('/index.php');
21 21
 }
Please login to merge, or discard this patch.
logout.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -28,34 +28,34 @@
 block discarded – undo
28 28
 
29 29
 $verified = $GLOBALS['egw']->session->verify();
30 30
 
31
-if(!($redirectTarget = Api\Cache::getSession('login', 'referer')))
31
+if (!($redirectTarget = Api\Cache::getSession('login', 'referer')))
32 32
 {
33 33
 	$redirectTarget = $GLOBALS['egw_info']['server']['webserver_url'].'/login.php?cd=1&domain='.$GLOBALS['egw_info']['user']['domain'];
34 34
 }
35
-elseif(strpos($redirectTarget, '[?&]cd=') !== false)
35
+elseif (strpos($redirectTarget, '[?&]cd=') !== false)
36 36
 {
37 37
 	$redirectTarget = preg_replace('/([?&])cd=[^&]+/', '$1cd=1', $redirectTarget);
38 38
 }
39 39
 
40
-if($verified)
40
+if ($verified)
41 41
 {
42 42
 	Api\Hooks::process('logout');
43
-	$GLOBALS['egw']->session->destroy($GLOBALS['sessionid'],$GLOBALS['kp3']);
43
+	$GLOBALS['egw']->session->destroy($GLOBALS['sessionid'], $GLOBALS['kp3']);
44 44
 }
45 45
 
46
-Api\Session::egw_setcookie('eGW_remember','',0,'/');
46
+Api\Session::egw_setcookie('eGW_remember', '', 0, '/');
47 47
 Api\Session::egw_setcookie('sessionid');
48 48
 Api\Session::egw_setcookie('kp3');
49 49
 Api\Session::egw_setcookie('domain');
50 50
 
51
-if($GLOBALS['egw_info']['server']['auth_type'] == 'cas')
51
+if ($GLOBALS['egw_info']['server']['auth_type'] == 'cas')
52 52
 {
53 53
 	require_once('CAS/CAS.php');
54 54
 
55 55
 	phpCAS::client(CAS_VERSION_2_0,
56 56
 								$GLOBALS['egw_info']['server']['cas_server_host_name'],
57
-								(int) $GLOBALS['egw_info']['server']['cas_server_port'],
58
-								$GLOBALS['egw_info']['server']['cas_server_uri'] );
57
+								(int)$GLOBALS['egw_info']['server']['cas_server_port'],
58
+								$GLOBALS['egw_info']['server']['cas_server_uri']);
59 59
 	phpCAS::logout(array('url'=>$GLOBALS['egw_info']['server']['webserver_url'].'/login.php?cd=1&domain='.$GLOBALS['egw_info']['user']['domain']));
60 60
 }
61 61
 
Please login to merge, or discard this patch.
share.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -18,10 +18,10 @@  discard block
 block discarded – undo
18 18
 	'flags' => array(
19 19
 		'disable_Template_class' => true,
20 20
 		'noheader'  => true,
21
-		'nonavbar' => 'always',	// true would cause eTemplate to reset it to false for non-popups!
21
+		'nonavbar' => 'always', // true would cause eTemplate to reset it to false for non-popups!
22 22
 		'currentapp' => 'filemanager',
23 23
 		'autocreate_session_callback' => 'EGroupware\\Api\\Vfs\\Sharing::create_session',
24
-		'no_exception_handler' => 'basic_auth',	// we use a basic auth exception handler (sends exception message as basic auth realm)
24
+		'no_exception_handler' => 'basic_auth', // we use a basic auth exception handler (sends exception message as basic auth realm)
25 25
 	)
26 26
 );
27 27
 
@@ -29,6 +29,6 @@  discard block
 block discarded – undo
29 29
 
30 30
 if (!$GLOBALS['egw']->sharing)
31 31
 {
32
-	Sharing::create_session(true);	// true = mount into existing session
32
+	Sharing::create_session(true); // true = mount into existing session
33 33
 }
34 34
 $GLOBALS['egw']->sharing->ServeRequest();
Please login to merge, or discard this patch.
files/webdav.php 2 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 {
35 35
 	if (isset($_GET['auth']))
36 36
 	{
37
-		list($_SERVER['PHP_AUTH_USER'],$_SERVER['PHP_AUTH_PW']) = explode(':',base64_decode($_GET['auth']),2);
37
+		list($_SERVER['PHP_AUTH_USER'], $_SERVER['PHP_AUTH_PW']) = explode(':', base64_decode($_GET['auth']), 2);
38 38
 	}
39 39
 	return Api\Header\Authenticate::autocreate_session_callback($account);
40 40
 }
@@ -45,8 +45,8 @@  discard block
 block discarded – undo
45 45
 		'noheader'  => True,
46 46
 		'currentapp' => preg_match('|/webdav.php/apps/([A-Za-z0-9_-]+)/|', $_SERVER['REQUEST_URI'], $matches) ? $matches[1] : 'filemanager',
47 47
 		'autocreate_session_callback' => 'check_access',
48
-		'no_exception_handler' => 'basic_auth',	// we use a basic auth exception handler (sends exception message as basic auth realm)
49
-		'auth_realm' => 'EGroupware WebDAV server',	// cant use Vfs\WebDAV::REALM as autoloading and include path not yet setup!
48
+		'no_exception_handler' => 'basic_auth', // we use a basic auth exception handler (sends exception message as basic auth realm)
49
+		'auth_realm' => 'EGroupware WebDAV server', // cant use Vfs\WebDAV::REALM as autoloading and include path not yet setup!
50 50
 	)
51 51
 );
52 52
 
@@ -74,12 +74,12 @@  discard block
 block discarded – undo
74 74
 
75 75
 // temporary mount ownCloud default /clientsync as /home/$user, if not explicitly mounted
76 76
 // so ownCloud dir contains users home-dir by default
77
-if (strpos($_SERVER['REQUEST_URI'],'/webdav.php/clientsync') !== false &&
78
-	($fstab=Vfs::mount()) && !isset($fstab['/clientsync']))
77
+if (strpos($_SERVER['REQUEST_URI'], '/webdav.php/clientsync') !== false &&
78
+	($fstab = Vfs::mount()) && !isset($fstab['/clientsync']))
79 79
 {
80 80
 	$is_root_backup = Vfs::$is_root;
81 81
 	Vfs::$is_root = true;
82
-	$ok = Vfs::mount($url='vfs://default/home/$user', $clientsync='/clientsync', null, false);
82
+	$ok = Vfs::mount($url = 'vfs://default/home/$user', $clientsync = '/clientsync', null, false);
83 83
 	Vfs::$is_root = $is_root_backup;
84 84
 	//error_log("mounting ownCloud default '$clientsync' as '$url' ".($ok ? 'successful' : 'failed!'));
85 85
 }
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
  * Create a session or if the user has no account return authenticate header and 401 Unauthorized
29 29
  *
30 30
  * @param array &$account
31
- * @return int session-id
31
+ * @return string session-id
32 32
  */
33 33
 function check_access(&$account)
34 34
 {
Please login to merge, or discard this patch.
timesheet/setup/default_records.inc.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
  * @version $Id$
10 10
  */
11 11
 
12
-foreach(array(
12
+foreach (array(
13 13
 	'history'     => 'history',
14 14
 ) as $name => $value)
15 15
 {
@@ -19,10 +19,10 @@  discard block
 block discarded – undo
19 19
 			'config_app' => 'timesheet',
20 20
 			'config_name' => $name,
21 21
 			'config_value' => $value,
22
-		),array(
22
+		), array(
23 23
 			'config_app' => 'timesheet',
24 24
 			'config_name' => $name,
25
-		),__LINE__,__FILE__
25
+		), __LINE__, __FILE__
26 26
 	);
27 27
 }
28 28
 
Please login to merge, or discard this patch.
timesheet/inc/class.timesheet_wizard_export_csv.inc.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
 		// Custom fields
25 25
 		unset($this->export_fields['customfields']);
26 26
 		$custom = Api\Storage\Customfields::get('timesheet', true);
27
-		foreach($custom as $name => $data) {
27
+		foreach ($custom as $name => $data) {
28 28
 			$this->export_fields['#'.$name] = $data['label'];
29 29
 		}
30 30
 	}
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,7 +14,8 @@  discard block
 block discarded – undo
14 14
 
15 15
 class timesheet_wizard_export_csv extends importexport_wizard_basic_export_csv
16 16
 {
17
-	public function __construct() {
17
+	public function __construct()
18
+	{
18 19
 		parent::__construct();
19 20
 
20 21
 		// Field mapping
@@ -24,7 +25,8 @@  discard block
 block discarded – undo
24 25
 		// Custom fields
25 26
 		unset($this->export_fields['customfields']);
26 27
 		$custom = Api\Storage\Customfields::get('timesheet', true);
27
-		foreach($custom as $name => $data) {
28
+		foreach($custom as $name => $data)
29
+		{
28 30
 			$this->export_fields['#'.$name] = $data['label'];
29 31
 		}
30 32
 	}
Please login to merge, or discard this patch.