Completed
Push — stable10 ( d1b390...0bd063 )
by Lukas
27:03 queued 26:40
created
apps/files_trashbin/ajax/list.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,8 +25,8 @@
 block discarded – undo
25 25
 \OC::$server->getSession()->close();
26 26
 
27 27
 // Load the files
28
-$dir = isset($_GET['dir']) ? (string)$_GET['dir'] : '';
29
-$sortAttribute = isset($_GET['sort']) ? (string)$_GET['sort'] : 'name';
28
+$dir = isset($_GET['dir']) ? (string) $_GET['dir'] : '';
29
+$sortAttribute = isset($_GET['sort']) ? (string) $_GET['sort'] : 'name';
30 30
 $sortDirection = isset($_GET['sortdirection']) ? ($_GET['sortdirection'] === 'desc') : false;
31 31
 $data = array();
32 32
 
Please login to merge, or discard this patch.
apps/files_trashbin/ajax/delete.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
 $folder = isset($_POST['dir']) ? $_POST['dir'] : '/';
32 32
 
33 33
 // "empty trash" command
34
-if (isset($_POST['allfiles']) && (string)$_POST['allfiles'] === 'true'){
34
+if (isset($_POST['allfiles']) && (string) $_POST['allfiles'] === 'true') {
35 35
 	$deleteAll = true;
36 36
 	if ($folder === '/' || $folder === '') {
37 37
 		OCA\Files_Trashbin\Trashbin::deleteAll();
@@ -43,11 +43,11 @@  discard block
 block discarded – undo
43 43
 }
44 44
 else {
45 45
 	$deleteAll = false;
46
-	$files = (string)$_POST['files'];
46
+	$files = (string) $_POST['files'];
47 47
 	$list = json_decode($files);
48 48
 }
49 49
 
50
-$folder = rtrim($folder, '/') . '/';
50
+$folder = rtrim($folder, '/').'/';
51 51
 $error = array();
52 52
 $success = array();
53 53
 
@@ -57,16 +57,16 @@  discard block
 block discarded – undo
57 57
 		$file = ltrim($file, '/');
58 58
 		$delimiter = strrpos($file, '.d');
59 59
 		$filename = substr($file, 0, $delimiter);
60
-		$timestamp =  substr($file, $delimiter+2);
60
+		$timestamp = substr($file, $delimiter + 2);
61 61
 	} else {
62
-		$filename = $folder . '/' . $file;
62
+		$filename = $folder.'/'.$file;
63 63
 		$timestamp = null;
64 64
 	}
65 65
 
66 66
 	OCA\Files_Trashbin\Trashbin::delete($filename, \OCP\User::getUser(), $timestamp);
67 67
 	if (OCA\Files_Trashbin\Trashbin::file_exists($filename, $timestamp)) {
68 68
 		$error[] = $filename;
69
-		\OCP\Util::writeLog('trashbin','can\'t delete ' . $filename . ' permanently.', \OCP\Util::ERROR);
69
+		\OCP\Util::writeLog('trashbin', 'can\'t delete '.$filename.' permanently.', \OCP\Util::ERROR);
70 70
 	}
71 71
 	// only list deleted files if not deleting everything
72 72
 	else if (!$deleteAll) {
@@ -76,9 +76,9 @@  discard block
 block discarded – undo
76 76
 	}
77 77
 }
78 78
 
79
-if ( $error ) {
79
+if ($error) {
80 80
 	$filelist = '';
81
-	foreach ( $error as $e ) {
81
+	foreach ($error as $e) {
82 82
 		$filelist .= $e.', ';
83 83
 	}
84 84
 	$l = \OC::$server->getL10N('files_trashbin');
Please login to merge, or discard this patch.
apps/files_trashbin/lib/AppInfo/Application.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
 use OCA\Files_Trashbin\Expiration;
28 28
 
29 29
 class Application extends App {
30
-	public function __construct (array $urlParams = []) {
30
+	public function __construct(array $urlParams = []) {
31 31
 		parent::__construct('files_trashbin', $urlParams);
32 32
 
33 33
 		$container = $this->getContainer();
Please login to merge, or discard this patch.
apps/files_trashbin/lib/Helper.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
 		$result = array();
45 45
 		$timestamp = null;
46 46
 
47
-		$view = new \OC\Files\View('/' . $user . '/files_trashbin/files');
47
+		$view = new \OC\Files\View('/'.$user.'/files_trashbin/files');
48 48
 
49 49
 		if (ltrim($dir, '/') !== '' && !$view->is_dir($dir)) {
50 50
 			throw new \Exception('Directory does not exists');
@@ -90,9 +90,9 @@  discard block
 block discarded – undo
90 90
 				'permissions' => Constants::PERMISSION_ALL - Constants::PERMISSION_SHARE
91 91
 			);
92 92
 			if ($originalPath) {
93
-				$i['extraData'] = $originalPath . '/' . $id;
93
+				$i['extraData'] = $originalPath.'/'.$id;
94 94
 			}
95
-			$result[] = new FileInfo($absoluteDir . '/' . $i['name'], $storage, $internalPath . '/' . $i['name'], $i, $mount);
95
+			$result[] = new FileInfo($absoluteDir.'/'.$i['name'], $storage, $internalPath.'/'.$i['name'], $i, $mount);
96 96
 		}
97 97
 
98 98
 		if ($sortAttribute !== '') {
Please login to merge, or discard this patch.
apps/files_trashbin/lib/Command/CleanUp.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -107,8 +107,8 @@
 block discarded – undo
107 107
 	protected function removeDeletedFiles($uid) {
108 108
 		\OC_Util::tearDownFS();
109 109
 		\OC_Util::setupFS($uid);
110
-		if ($this->rootFolder->nodeExists('/' . $uid . '/files_trashbin')) {
111
-			$this->rootFolder->get('/' . $uid . '/files_trashbin')->delete();
110
+		if ($this->rootFolder->nodeExists('/'.$uid.'/files_trashbin')) {
111
+			$this->rootFolder->get('/'.$uid.'/files_trashbin')->delete();
112 112
 			$query = $this->dbConnection->getQueryBuilder();
113 113
 			$query->delete('files_trash')
114 114
 				->where($query->expr()->eq('user', $query->createParameter('uid')))
Please login to merge, or discard this patch.
apps/files_trashbin/lib/Hooks.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
 	 * to remove the used space for the trash bin stored in the database
40 40
 	 */
41 41
 	public static function deleteUser_hook($params) {
42
-		if( \OCP\App::isEnabled('files_trashbin') ) {
42
+		if (\OCP\App::isEnabled('files_trashbin')) {
43 43
 			$uid = $params['uid'];
44 44
 			Trashbin::deleteUser($uid);
45 45
 		}
Please login to merge, or discard this patch.
apps/files_trashbin/lib/Expiration.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 	/** @var bool */
48 48
 	private $canPurgeToSaveSpace;
49 49
 
50
-	public function __construct(IConfig $config,ITimeFactory $timeFactory){
50
+	public function __construct(IConfig $config, ITimeFactory $timeFactory) {
51 51
 		$this->timeFactory = $timeFactory;
52 52
 		$this->retentionObligation = $config->getSystemValue('trashbin_retention_obligation', 'auto');
53 53
 
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
 	 * Is trashbin expiration enabled
61 61
 	 * @return bool
62 62
 	 */
63
-	public function isEnabled(){
63
+	public function isEnabled() {
64 64
 		return $this->retentionObligation !== 'disabled';
65 65
 	}
66 66
 
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 	 * @param bool $quotaExceeded
71 71
 	 * @return bool
72 72
 	 */
73
-	public function isExpired($timestamp, $quotaExceeded = false){
73
+	public function isExpired($timestamp, $quotaExceeded = false) {
74 74
 		// No expiration if disabled
75 75
 		if (!$this->isEnabled()) {
76 76
 			return false;
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
 		$time = $this->timeFactory->getTime();
85 85
 		// Never expire dates in future e.g. misconfiguration or negative time
86 86
 		// adjustment
87
-		if ($time<$timestamp) {
87
+		if ($time < $timestamp) {
88 88
 			return false;
89 89
 		}
90 90
 
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
 		return $maxAge;
120 120
 	}
121 121
 
122
-	private function parseRetentionObligation(){
122
+	private function parseRetentionObligation() {
123 123
 		$splitValues = explode(',', $this->retentionObligation);
124 124
 		if (!isset($splitValues[0])) {
125 125
 			$minValue = self::DEFAULT_RETENTION_OBLIGATION;
Please login to merge, or discard this patch.
apps/files_trashbin/appinfo/update.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
 	$newObligation = 'auto';
32 32
 	if ($isExpirationEnabled) {
33 33
 		if (!is_null($oldObligation)) {
34
-			$newObligation = strval($oldObligation) . ', auto';
34
+			$newObligation = strval($oldObligation).', auto';
35 35
 		}
36 36
 	} else {
37 37
 		$newObligation = 'disabled';
Please login to merge, or discard this patch.
apps/workflowengine/templates/admin.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
 
28 28
 	<?php if (!empty($_['docs'])): ?>
29 29
 		<a target="_blank" rel="noreferrer" class="icon-info svg"
30
-		   title="<?php p($l->t('Open documentation'));?>"
30
+		   title="<?php p($l->t('Open documentation')); ?>"
31 31
 		   href="<?php p(link_to_docs($_['docs'])); ?>">
32 32
 		</a>
33 33
 	<?php endif; ?>
Please login to merge, or discard this patch.