Ver Fonte

Fix null exception in shares (#1898)

https://github.com/FreshRSS/FreshRSS/issues/1824
https://github.com/FreshRSS/FreshRSS/issues/1884
Alexandre Alapetite há 7 anos atrás
pai
commit
7ebc56e8d3
2 ficheiros alterados com 4 adições e 0 exclusões
  1. 1 0
      CHANGELOG.md
  2. 3 0
      app/views/helpers/index/normal/entry_bottom.phtml

+ 1 - 0
CHANGELOG.md

@@ -22,6 +22,7 @@
 * Bug fixing
 	* Fix Docker bug affecting Apache `CustomLog` (unwanted local copy of access logs), `ErrorLog`, `Listen` (IPv6 bug) [#1873](https://github.com/FreshRSS/FreshRSS/pull/1873)
 	* Fix muted feeds that were not actually muted [#1844](https://github.com/FreshRSS/FreshRSS/issues/1844)
+	* Fix null exception in shares, showing only the first article [#1824](https://github.com/FreshRSS/FreshRSS/issues/1824)
 	* Fix errors in case of empty/wrong username when updating user settings [#1857](https://github.com/FreshRSS/FreshRSS/pull/1857)
 	* Fixes in subscription menu [#1858](https://github.com/FreshRSS/FreshRSS/pull/1858)
 	* Fix allowing Unix sockets for MySQL and PostgreSQL [#1888](https://github.com/FreshRSS/FreshRSS/issues/1888)

+ 3 - 0
app/views/helpers/index/normal/entry_bottom.phtml

@@ -48,6 +48,9 @@
 					$title = $this->entry->title() . ' · ' . $this->feed->name();
 					foreach (FreshRSS_Context::$user_conf->sharing as $share_options) {
 						$share = FreshRSS_Share::get($share_options['type']);
+						if ($share === null) {
+							continue;
+						}
 						$share_options['link'] = $link;
 						$share_options['title'] = $title;
 						$share->update($share_options);