Passed
Push — master ( d1af72...ccd8da )
by Roeland
33:49 queued 22:20
created
lib/public/Util.php 1 patch
Spacing   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -60,23 +60,23 @@  discard block
 block discarded – undo
60 60
 	/**
61 61
 	 * @deprecated 14.0.0 use \OCP\ILogger::DEBUG
62 62
 	 */
63
-	const DEBUG=0;
63
+	const DEBUG = 0;
64 64
 	/**
65 65
 	 * @deprecated 14.0.0 use \OCP\ILogger::INFO
66 66
 	 */
67
-	const INFO=1;
67
+	const INFO = 1;
68 68
 	/**
69 69
 	 * @deprecated 14.0.0 use \OCP\ILogger::WARN
70 70
 	 */
71
-	const WARN=2;
71
+	const WARN = 2;
72 72
 	/**
73 73
 	 * @deprecated 14.0.0 use \OCP\ILogger::ERROR
74 74
 	 */
75
-	const ERROR=3;
75
+	const ERROR = 3;
76 76
 	/**
77 77
 	 * @deprecated 14.0.0 use \OCP\ILogger::FATAL
78 78
 	 */
79
-	const FATAL=4;
79
+	const FATAL = 4;
80 80
 
81 81
 	/** \OCP\Share\IManager */
82 82
 	private static $shareManager;
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
 	 * @since 4.0.0
117 117
 	 * @deprecated 13.0.0 use log of \OCP\ILogger
118 118
 	 */
119
-	public static function writeLog( $app, $message, $level ) {
119
+	public static function writeLog($app, $message, $level) {
120 120
 		$context = ['app' => $app];
121 121
 		\OC::$server->getLogger()->log($level, $message, $context);
122 122
 	}
@@ -158,8 +158,8 @@  discard block
 block discarded – undo
158 158
 	 * @param string $file
159 159
 	 * @since 4.0.0
160 160
 	 */
161
-	public static function addStyle( $application, $file = null ) {
162
-		\OC_Util::addStyle( $application, $file );
161
+	public static function addStyle($application, $file = null) {
162
+		\OC_Util::addStyle($application, $file);
163 163
 	}
164 164
 
165 165
 	/**
@@ -168,8 +168,8 @@  discard block
 block discarded – undo
168 168
 	 * @param string $file
169 169
 	 * @since 4.0.0
170 170
 	 */
171
-	public static function addScript( $application, $file = null ) {
172
-		\OC_Util::addScript( $application, $file );
171
+	public static function addScript($application, $file = null) {
172
+		\OC_Util::addScript($application, $file);
173 173
 	}
174 174
 
175 175
 	/**
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
 	 * @param string $text the text content for the element
192 192
 	 * @since 4.0.0
193 193
 	 */
194
-	public static function addHeader($tag, $attributes, $text=null) {
194
+	public static function addHeader($tag, $attributes, $text = null) {
195 195
 		\OC_Util::addHeader($tag, $attributes, $text);
196 196
 	}
197 197
 
@@ -204,7 +204,7 @@  discard block
 block discarded – undo
204 204
 	 * @return string the url
205 205
 	 * @since 4.0.0 - parameter $args was added in 4.5.0
206 206
 	 */
207
-	public static function linkToAbsolute( $app, $file, $args = array() ) {
207
+	public static function linkToAbsolute($app, $file, $args = array()) {
208 208
 		$urlGenerator = \OC::$server->getURLGenerator();
209 209
 		return $urlGenerator->getAbsoluteURL(
210 210
 			$urlGenerator->linkTo($app, $file, $args)
@@ -217,11 +217,11 @@  discard block
 block discarded – undo
217 217
 	 * @return string the url
218 218
 	 * @since 4.0.0
219 219
 	 */
220
-	public static function linkToRemote( $service ) {
220
+	public static function linkToRemote($service) {
221 221
 		$urlGenerator = \OC::$server->getURLGenerator();
222
-		$remoteBase = $urlGenerator->linkTo('', 'remote.php') . '/' . $service;
222
+		$remoteBase = $urlGenerator->linkTo('', 'remote.php').'/'.$service;
223 223
 		return $urlGenerator->getAbsoluteURL(
224
-			$remoteBase . (($service[strlen($service) - 1] != '/') ? '/' : '')
224
+			$remoteBase.(($service[strlen($service) - 1] != '/') ? '/' : '')
225 225
 		);
226 226
 	}
227 227
 
@@ -354,7 +354,7 @@  discard block
 block discarded – undo
354 354
 	 * @since 4.5.0
355 355
 	 */
356 356
 	public static function callRegister() {
357
-		if(self::$token === '') {
357
+		if (self::$token === '') {
358 358
 			self::$token = \OC::$server->getCsrfTokenManager()->getToken()->getEncryptedValue();
359 359
 		}
360 360
 		return self::$token;
@@ -500,7 +500,7 @@  discard block
 block discarded – undo
500 500
 	 */
501 501
 	public static function needUpgrade() {
502 502
 		if (!isset(self::$needUpgradeCache)) {
503
-			self::$needUpgradeCache=\OC_Util::needUpgrade(\OC::$server->getSystemConfig());
503
+			self::$needUpgradeCache = \OC_Util::needUpgrade(\OC::$server->getSystemConfig());
504 504
 		}		
505 505
 		return self::$needUpgradeCache;
506 506
 	}
Please login to merge, or discard this patch.