Passed
Push — master ( 5a5c41...fade3b )
by Cody
04:50 queued 10s
created
plugins/cache_starred_images/init.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 	public function hook_house_keeping() {
36 36
 		/* since HOOK_UPDATE_TASK is not available to user plugins, this hook is a next best thing */
37 37
 
38
-		Debug::log("caching media of starred articles for user " . $this->host->get_owner_uid() . "...");
38
+		Debug::log("caching media of starred articles for user ".$this->host->get_owner_uid()."...");
39 39
 
40 40
 		$sth = $this->pdo->prepare("SELECT content, ttrss_entries.title,
41 41
        		ttrss_user_entries.owner_uid, link, site_url, ttrss_entries.id, plugin_data
@@ -53,13 +53,13 @@  discard block
 block discarded – undo
53 53
 			$usth = $this->pdo->prepare("UPDATE ttrss_entries SET plugin_data = ? WHERE id = ?");
54 54
 
55 55
 			while ($line = $sth->fetch()) {
56
-				Debug::log("processing article " . $line["title"], Debug::$LOG_VERBOSE);
56
+				Debug::log("processing article ".$line["title"], Debug::$LOG_VERBOSE);
57 57
 
58 58
 				if ($line["site_url"]) {
59 59
 					$success = $this->cache_article_images($line["content"], $line["site_url"], $line["owner_uid"], $line["id"]);
60 60
 
61 61
 					if ($success) {
62
-						$plugin_data = "starred_cache_images,${line['owner_uid']}:" . $line["plugin_data"];
62
+						$plugin_data = "starred_cache_images,${line['owner_uid']}:".$line["plugin_data"];
63 63
 
64 64
 						$usth->execute([$plugin_data, $line['id']]);
65 65
 					}
@@ -69,9 +69,9 @@  discard block
 block discarded – undo
69 69
 
70 70
 		/* actual housekeeping */
71 71
 
72
-		Debug::log("expiring " . $this->cache->getDir() . "...");
72
+		Debug::log("expiring ".$this->cache->getDir()."...");
73 73
 
74
-		$files = glob($this->cache->getDir() . "/*.{png,mp4,status}", GLOB_BRACE);
74
+		$files = glob($this->cache->getDir()."/*.{png,mp4,status}", GLOB_BRACE);
75 75
 
76 76
 		$last_article_id = 0;
77 77
 		$article_exists = 1;
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
 	}
96 96
 
97 97
 	public function hook_enclosure_entry($enc, $article_id) {
98
-		$local_filename = $article_id . "-" . sha1($enc["content_url"]);
98
+		$local_filename = $article_id."-".sha1($enc["content_url"]);
99 99
 
100 100
 		if ($this->cache->exists($local_filename)) {
101 101
 			$enc["content_url"] = $this->cache->getUrl($local_filename);
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
 				if ($entry->hasAttribute('src')) {
115 115
 					$src = rewrite_relative_url($site_url, $entry->getAttribute('src'));
116 116
 
117
-					$local_filename = $article_id . "-" . sha1($src);
117
+					$local_filename = $article_id."-".sha1($src);
118 118
 
119 119
 					if ($this->cache->exists($local_filename)) {
120 120
 						$entry->setAttribute("src", $this->cache->getUrl($local_filename));
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
 	}
129 129
 
130 130
 	private function cache_url($article_id, $url) {
131
-		$local_filename = $article_id . "-" . sha1($url);
131
+		$local_filename = $article_id."-".sha1($url);
132 132
 
133 133
 		if (!$this->cache->exists($local_filename)) {
134 134
 			Debug::log("cache_images: downloading: $url to $local_filename", Debug::$LOG_VERBOSE);
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
 			$data = fetch_file_contents(["url" => $url, "max_size" => MAX_CACHE_FILE_SIZE]);
137 137
 
138 138
 			if ($data)
139
-				return $this->cache->put($local_filename, $data);;
139
+				return $this->cache->put($local_filename, $data); ;
140 140
 
141 141
 		} else {
142 142
 			//Debug::log("cache_images: local file exists for $url", Debug::$LOG_VERBOSE);
@@ -148,7 +148,7 @@  discard block
 block discarded – undo
148 148
 	}
149 149
 
150 150
 	private function cache_article_images($content, $site_url, $owner_uid, $article_id) {
151
-		$status_filename = $article_id . "-" . sha1($site_url) . ".status";
151
+		$status_filename = $article_id."-".sha1($site_url).".status";
152 152
 
153 153
 		/* housekeeping might run as a separate user, in this case status/media might not be writable */
154 154
 		if (!$this->cache->isWritable($status_filename)) {
@@ -181,7 +181,7 @@  discard block
 block discarded – undo
181 181
 		$has_images = false;
182 182
 		$success = false;
183 183
 
184
-        if ($doc->loadHTML('<?xml encoding="UTF-8">' . $content)) {
184
+        if ($doc->loadHTML('<?xml encoding="UTF-8">'.$content)) {
185 185
 			$xpath = new DOMXPath($doc);
186 186
 			$entries = $xpath->query('(//img[@src])|(//video/source[@src])');
187 187
 
Please login to merge, or discard this patch.
plugins/share/init.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -17,15 +17,15 @@  discard block
 block discarded – undo
17 17
 	}
18 18
 
19 19
 	public function get_js() {
20
-		return file_get_contents(dirname(__FILE__) . "/share.js");
20
+		return file_get_contents(dirname(__FILE__)."/share.js");
21 21
 	}
22 22
 
23 23
 	public function get_css() {
24
-		return file_get_contents(dirname(__FILE__) . "/share.css");
24
+		return file_get_contents(dirname(__FILE__)."/share.css");
25 25
 	}
26 26
 
27 27
 	public function get_prefs_js() {
28
-		return file_get_contents(dirname(__FILE__) . "/share_prefs.js");
28
+		return file_get_contents(dirname(__FILE__)."/share_prefs.js");
29 29
 	}
30 30
 
31 31
 
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
 	public function hook_prefs_tab_section($id) {
43 43
 		if ($id == "prefFeedsPublishedGenerated") {
44 44
 
45
-			print "<h3>" . __("You can disable all articles shared by unique URLs here.") . "</h3>";
45
+			print "<h3>".__("You can disable all articles shared by unique URLs here.")."</h3>";
46 46
 
47 47
 			print "<button class='alt-danger' dojoType='dijit.form.Button' onclick=\"return Plugins.Share.clearKeys()\">".
48 48
 				__('Unshare all articles')."</button> ";
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
 				$sth->execute([$uuid, $param, $_SESSION['uid']]);
101 101
 			}
102 102
 
103
-			print "<header>" . __("You can share this article by the following unique URL:") . "</header>";
103
+			print "<header>".__("You can share this article by the following unique URL:")."</header>";
104 104
 
105 105
 			$url_path = get_self_url_prefix();
106 106
 			$url_path .= "/public.php?op=share&key=$uuid";
Please login to merge, or discard this patch.
plugins/af_zz_noautoplay/init.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
 	}
14 14
 
15 15
 	public function get_js() {
16
-		return file_get_contents(__DIR__ . "/init.js");
16
+		return file_get_contents(__DIR__."/init.js");
17 17
 	}
18 18
 
19 19
 	public function api_version() {
Please login to merge, or discard this patch.
plugins/no_url_hashes/init.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@
 block discarded – undo
14 14
 	}
15 15
 
16 16
 	public function get_js() {
17
-		return file_get_contents(__DIR__ . "/init.js");
17
+		return file_get_contents(__DIR__."/init.js");
18 18
 	}
19 19
 
20 20
 	public function api_version() {
Please login to merge, or discard this patch.
plugins/mail/init.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
 	}
19 19
 
20 20
 	public function get_js() {
21
-		return file_get_contents(dirname(__FILE__) . "/mail.js");
21
+		return file_get_contents(dirname(__FILE__)."/mail.js");
22 22
 	}
23 23
 
24 24
 	public function save() {
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 		print "<div dojoType=\"dijit.layout.AccordionPane\"
36 36
 			title=\"<i class='material-icons'>mail</i> ".__('Mail plugin')."\">";
37 37
 
38
-		print "<p>" . __("You can set predefined email addressed here (comma-separated list):") . "</p>";
38
+		print "<p>".__("You can set predefined email addressed here (comma-separated list):")."</p>";
39 39
 
40 40
 		print "<form dojoType=\"dijit.form.Form\">";
41 41
 
@@ -115,17 +115,17 @@  discard block
 block discarded – undo
115 115
 		$sth->execute(array_merge($ids, [$_SESSION['uid']]));
116 116
 
117 117
 		if (count($ids) > 1) {
118
-			$subject = __("[Forwarded]") . " " . __("Multiple articles");
118
+			$subject = __("[Forwarded]")." ".__("Multiple articles");
119 119
 		}
120 120
 
121 121
 		while ($line = $sth->fetch()) {
122 122
 
123 123
 			if (!$subject)
124
-				$subject = __("[Forwarded]") . " " . htmlspecialchars($line["title"]);
124
+				$subject = __("[Forwarded]")." ".htmlspecialchars($line["title"]);
125 125
 
126 126
 			$tpl->setVariable('ARTICLE_TITLE', strip_tags($line["title"]));
127 127
 			$tnote = strip_tags($line["note"]);
128
-			if( $tnote != ''){
128
+			if ($tnote != '') {
129 129
 				$tpl->setVariable('ARTICLE_NOTE', $tnote, true);
130 130
 				$tpl->addBlock('note');
131 131
 			}
@@ -210,7 +210,7 @@  discard block
 block discarded – undo
210 210
 			"message" => $message]);
211 211
 
212 212
 		if (!$rc) {
213
-			$reply['error'] =  $mailer->error();
213
+			$reply['error'] = $mailer->error();
214 214
 		} else {
215 215
 			//save_email_address($destination);
216 216
 			$reply['message'] = "UPDATE_COUNTERS";
Please login to merge, or discard this patch.
plugins/af_comics/init.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -19,9 +19,9 @@  discard block
 block discarded – undo
19 19
 		$host->add_hook($host::HOOK_ARTICLE_FILTER, $this);
20 20
 		$host->add_hook($host::HOOK_PREFS_TAB, $this);
21 21
 
22
-		require_once __DIR__ . "/filter_base.php";
22
+		require_once __DIR__."/filter_base.php";
23 23
 
24
-		$filters = array_merge(glob(__DIR__ . "/filters.local/*.php"), glob(__DIR__ . "/filters/*.php"));
24
+		$filters = array_merge(glob(__DIR__."/filters.local/*.php"), glob(__DIR__."/filters/*.php"));
25 25
 		$names = [];
26 26
 
27 27
 		foreach ($filters as $file) {
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
 		print "<div dojoType=\"dijit.layout.AccordionPane\"
51 51
 			title=\"<i class='material-icons'>photo</i> ".__('Feeds supported by af_comics')."\">";
52 52
 
53
-		print "<p>" . __("The following comics are currently supported:") . "</p>";
53
+		print "<p>".__("The following comics are currently supported:")."</p>";
54 54
 
55 55
 		$comics = array("GoComics");
56 56
 
@@ -93,9 +93,9 @@  discard block
 block discarded – undo
93 93
 			return $feed_data;
94 94
 
95 95
 		if (preg_match('#^https?://(?:feeds\.feedburner\.com/uclick|www\.gocomics\.com)/([-a-z0-9]+)$#i', $fetch_url, $comic)) {
96
-			$site_url = 'https://www.gocomics.com/' . $comic[1];
96
+			$site_url = 'https://www.gocomics.com/'.$comic[1];
97 97
 
98
-			$article_link = $site_url . date('/Y/m/d');
98
+			$article_link = $site_url.date('/Y/m/d');
99 99
 
100 100
 			$body = fetch_file_contents(array('url' => $article_link, 'type' => 'text/html', 'followlocation' => false));
101 101
 
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
 							$title = date('l, F d, Y');
132 132
 						}
133 133
 
134
-						foreach (['srcset', 'sizes', 'data-srcset', 'width'] as $attr ) {
134
+						foreach (['srcset', 'sizes', 'data-srcset', 'width'] as $attr) {
135 135
 							$node->removeAttribute($attr);
136 136
 						}
137 137
 
Please login to merge, or discard this patch.
plugins/shorten_expanded/init.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,11 +14,11 @@
 block discarded – undo
14 14
 	}
15 15
 
16 16
 	public function get_css() {
17
-		return file_get_contents(__DIR__ . "/init.css");
17
+		return file_get_contents(__DIR__."/init.css");
18 18
 	}
19 19
 
20 20
 	public function get_js() {
21
-		return file_get_contents(__DIR__ . "/init.js");
21
+		return file_get_contents(__DIR__."/init.js");
22 22
 	}
23 23
 
24 24
 	public function api_version() {
Please login to merge, or discard this patch.
plugins/af_zz_vidmute/init.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
 	}
14 14
 
15 15
 	public function get_js() {
16
-		return file_get_contents(__DIR__ . "/init.js");
16
+		return file_get_contents(__DIR__."/init.js");
17 17
 	}
18 18
 
19 19
 	public function api_version() {
Please login to merge, or discard this patch.
plugins/search_sphinx/init.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 			user_error("Your PHP has a separate systemwide Sphinx client installed which conflicts with the client library used by tt-rss. Either remove the system library or disable Sphinx support.");
18 18
 		}
19 19
 
20
-		require_once __DIR__ . "/sphinxapi.php";
20
+		require_once __DIR__."/sphinxapi.php";
21 21
 	}
22 22
 
23 23
 	public function hook_search($search) {
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
 
29 29
 		$sphinxpair = explode(":", SPHINX_SERVER, 2);
30 30
 
31
-		$sphinxClient->SetServer($sphinxpair[0], (int)$sphinxpair[1]);
31
+		$sphinxClient->SetServer($sphinxpair[0], (int) $sphinxpair[1]);
32 32
 		$sphinxClient->SetConnectTimeout(1);
33 33
 
34 34
 		$sphinxClient->SetFieldWeights(array('title' => 70, 'content' => 30,
Please login to merge, or discard this patch.