Spotlight Social Media Feeds - Version 0.9.5

Version Description

(2021-08-16) =

Fixed - Videos in gallery posts had broken URLs and could not be played from the popup box - Feeds only imported posts automatically from the first source

Download this release

Release Info

Developer Mekku
Plugin Icon 128x128 Spotlight Social Media Feeds
Version 0.9.5
Comparing to
See all releases

Code changes from version 0.9.4 to 0.9.5

core/Actions/IgImageProxy.php CHANGED
@@ -71,9 +71,10 @@ class IgImageProxy
71
  $children = $item->get(MediaItem::CHILDREN, []);
72
 
73
  foreach ($children as $idx => $child) {
 
74
  $shortcode = $child[MediaItem::SHORTCODE] ?? null;
75
 
76
- if (!empty($shortcode)) {
77
  $children[$idx][MediaItem::MEDIA_URL] = IgImageProxy::getUrl($shortcode, 'l');
78
  }
79
  }
71
  $children = $item->get(MediaItem::CHILDREN, []);
72
 
73
  foreach ($children as $idx => $child) {
74
+ $type = $child[MediaItem::MEDIA_TYPE] ?? null;
75
  $shortcode = $child[MediaItem::SHORTCODE] ?? null;
76
 
77
+ if ($type === MediaType::IMAGE && !empty($shortcode)) {
78
  $children[$idx][MediaItem::MEDIA_URL] = IgImageProxy::getUrl($shortcode, 'l');
79
  }
80
  }
core/Server.php CHANGED
@@ -51,12 +51,16 @@ class Server
51
  $mainResult = $this->engine->getAggregator()->aggregate($feed, $num, $from);
52
  $needImport = (count($mainResult->items) === 0);
53
 
54
- if ($needImport) {
55
- try {
56
- $sourceItems = $this->engine->getStore()->getForSources($feed->sources, 1);
57
- $needImport = count($sourceItems) === 0;
58
- } catch (Exception $e) {
59
- // Fail silently
 
 
 
 
60
  }
61
  }
62
 
51
  $mainResult = $this->engine->getAggregator()->aggregate($feed, $num, $from);
52
  $needImport = (count($mainResult->items) === 0);
53
 
54
+ if (!$needImport) {
55
+ // Check each feed source whether an import is required
56
+ foreach ($feed->sources as $source) {
57
+ try {
58
+ $sourceItems = $this->engine->getStore()->getForSources([$source], 1);
59
+ $needImport = $needImport || count($sourceItems) === 0;
60
+ } catch (Exception $e) {
61
+ // Fail silently
62
+ continue;
63
+ }
64
  }
65
  }
66
 
plugin.json CHANGED
@@ -1,7 +1,7 @@
1
  {
2
  "name": "Spotlight - Social Media Feeds",
3
  "description": "Easily embed beautiful Instagram feeds on your WordPress site.",
4
- "version": "0.9.4",
5
  "url": "https://spotlightwp.com",
6
  "author": "RebelCode",
7
  "authorUrl": "https://rebelcode.com",
1
  {
2
  "name": "Spotlight - Social Media Feeds",
3
  "description": "Easily embed beautiful Instagram feeds on your WordPress site.",
4
+ "version": "0.9.5",
5
  "url": "https://spotlightwp.com",
6
  "author": "RebelCode",
7
  "authorUrl": "https://rebelcode.com",
plugin.php CHANGED
@@ -5,7 +5,7 @@
5
  *
6
  * Plugin Name: Spotlight - Social Media Feeds
7
  * Description: Easily embed beautiful Instagram feeds on your WordPress site.
8
- * Version: 0.9.4
9
  * Author: RebelCode
10
  * Plugin URI: https://spotlightwp.com
11
  * Author URI: https://rebelcode.com
@@ -80,7 +80,7 @@ $bootstrapper = function (SlInstaRuntime $sli) use ($thisIsPro) {
80
  // The plugin name
81
  define('SL_INSTA_NAME', 'Spotlight - Social Media Feeds');
82
  // The plugin version
83
- define('SL_INSTA_VERSION', '0.9.4');
84
  // The path to the plugin's main file
85
  define('SL_INSTA_FILE', __FILE__);
86
  // The dir to the plugin's directory
5
  *
6
  * Plugin Name: Spotlight - Social Media Feeds
7
  * Description: Easily embed beautiful Instagram feeds on your WordPress site.
8
+ * Version: 0.9.5
9
  * Author: RebelCode
10
  * Plugin URI: https://spotlightwp.com
11
  * Author URI: https://rebelcode.com
80
  // The plugin name
81
  define('SL_INSTA_NAME', 'Spotlight - Social Media Feeds');
82
  // The plugin version
83
+ define('SL_INSTA_VERSION', '0.9.5');
84
  // The path to the plugin's main file
85
  define('SL_INSTA_FILE', __FILE__);
86
  // The dir to the plugin's directory
readme.txt CHANGED
@@ -6,7 +6,7 @@ Tags: Instagram, Instagram feed, Instagram feeds, Instagram widget, Instagram em
6
  Requires at least: 5.3
7
  Requires PHP: 7.1
8
  Tested up to: 5.8
9
- Stable tag: 0.9.4
10
  License: GPLv3
11
 
12
  Instagram feeds for your WordPress site. A simple no-code solution to embed your Instagram account anywhere on your website in seconds.
@@ -270,6 +270,12 @@ There are a few reasons that this may happen. We have documented the reasons and
270
 
271
  == Changelog ==
272
 
 
 
 
 
 
 
273
  = 0.9.4 (2021-08-12) =
274
 
275
  **Fixed**
6
  Requires at least: 5.3
7
  Requires PHP: 7.1
8
  Tested up to: 5.8
9
+ Stable tag: 0.9.5
10
  License: GPLv3
11
 
12
  Instagram feeds for your WordPress site. A simple no-code solution to embed your Instagram account anywhere on your website in seconds.
270
 
271
  == Changelog ==
272
 
273
+ = 0.9.5 (2021-08-16) =
274
+
275
+ **Fixed**
276
+ - Videos in gallery posts had broken URLs and could not be played from the popup box
277
+ - Feeds only imported posts automatically from the first source
278
+
279
  = 0.9.4 (2021-08-12) =
280
 
281
  **Fixed**
vendor/autoload.php CHANGED
@@ -4,4 +4,4 @@
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
- return ComposerAutoloaderInit0889502cf631a7b60d967a025f8b0e4c::getLoader();
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
+ return ComposerAutoloaderInit0bb20f12ee9e70ddc31df259f96fd925::getLoader();
vendor/composer/autoload_psr4.php CHANGED
@@ -15,7 +15,7 @@ return array(
15
  'RebelCode\\Iris\\' => array($vendorDir . '/rebelcode/iris-engine/src'),
16
  'Psr\\SimpleCache\\' => array($vendorDir . '/psr/simple-cache/src'),
17
  'Psr\\Log\\' => array($vendorDir . '/psr/log/Psr/Log'),
18
- 'Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-message/src', $vendorDir . '/psr/http-factory/src'),
19
  'Psr\\Http\\Client\\' => array($vendorDir . '/psr/http-client/src'),
20
  'Psr\\Container\\' => array($vendorDir . '/psr/container/src'),
21
  'Liborm85\\ComposerVendorCleaner\\' => array($vendorDir . '/liborm85/composer-vendor-cleaner/src'),
15
  'RebelCode\\Iris\\' => array($vendorDir . '/rebelcode/iris-engine/src'),
16
  'Psr\\SimpleCache\\' => array($vendorDir . '/psr/simple-cache/src'),
17
  'Psr\\Log\\' => array($vendorDir . '/psr/log/Psr/Log'),
18
+ 'Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-factory/src', $vendorDir . '/psr/http-message/src'),
19
  'Psr\\Http\\Client\\' => array($vendorDir . '/psr/http-client/src'),
20
  'Psr\\Container\\' => array($vendorDir . '/psr/container/src'),
21
  'Liborm85\\ComposerVendorCleaner\\' => array($vendorDir . '/liborm85/composer-vendor-cleaner/src'),
vendor/composer/autoload_real.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
- class ComposerAutoloaderInit0889502cf631a7b60d967a025f8b0e4c
6
  {
7
  private static $loader;
8
 
@@ -22,15 +22,15 @@ class ComposerAutoloaderInit0889502cf631a7b60d967a025f8b0e4c
22
  return self::$loader;
23
  }
24
 
25
- spl_autoload_register(array('ComposerAutoloaderInit0889502cf631a7b60d967a025f8b0e4c', 'loadClassLoader'), true, true);
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
27
- spl_autoload_unregister(array('ComposerAutoloaderInit0889502cf631a7b60d967a025f8b0e4c', 'loadClassLoader'));
28
 
29
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
30
  if ($useStaticLoader) {
31
  require __DIR__ . '/autoload_static.php';
32
 
33
- call_user_func(\Composer\Autoload\ComposerStaticInit0889502cf631a7b60d967a025f8b0e4c::getInitializer($loader));
34
  } else {
35
  $map = require __DIR__ . '/autoload_namespaces.php';
36
  foreach ($map as $namespace => $path) {
@@ -51,19 +51,19 @@ class ComposerAutoloaderInit0889502cf631a7b60d967a025f8b0e4c
51
  $loader->register(true);
52
 
53
  if ($useStaticLoader) {
54
- $includeFiles = Composer\Autoload\ComposerStaticInit0889502cf631a7b60d967a025f8b0e4c::$files;
55
  } else {
56
  $includeFiles = require __DIR__ . '/autoload_files.php';
57
  }
58
  foreach ($includeFiles as $fileIdentifier => $file) {
59
- composerRequire0889502cf631a7b60d967a025f8b0e4c($fileIdentifier, $file);
60
  }
61
 
62
  return $loader;
63
  }
64
  }
65
 
66
- function composerRequire0889502cf631a7b60d967a025f8b0e4c($fileIdentifier, $file)
67
  {
68
  if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
69
  require $file;
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
+ class ComposerAutoloaderInit0bb20f12ee9e70ddc31df259f96fd925
6
  {
7
  private static $loader;
8
 
22
  return self::$loader;
23
  }
24
 
25
+ spl_autoload_register(array('ComposerAutoloaderInit0bb20f12ee9e70ddc31df259f96fd925', 'loadClassLoader'), true, true);
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
27
+ spl_autoload_unregister(array('ComposerAutoloaderInit0bb20f12ee9e70ddc31df259f96fd925', 'loadClassLoader'));
28
 
29
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
30
  if ($useStaticLoader) {
31
  require __DIR__ . '/autoload_static.php';
32
 
33
+ call_user_func(\Composer\Autoload\ComposerStaticInit0bb20f12ee9e70ddc31df259f96fd925::getInitializer($loader));
34
  } else {
35
  $map = require __DIR__ . '/autoload_namespaces.php';
36
  foreach ($map as $namespace => $path) {
51
  $loader->register(true);
52
 
53
  if ($useStaticLoader) {
54
+ $includeFiles = Composer\Autoload\ComposerStaticInit0bb20f12ee9e70ddc31df259f96fd925::$files;
55
  } else {
56
  $includeFiles = require __DIR__ . '/autoload_files.php';
57
  }
58
  foreach ($includeFiles as $fileIdentifier => $file) {
59
+ composerRequire0bb20f12ee9e70ddc31df259f96fd925($fileIdentifier, $file);
60
  }
61
 
62
  return $loader;
63
  }
64
  }
65
 
66
+ function composerRequire0bb20f12ee9e70ddc31df259f96fd925($fileIdentifier, $file)
67
  {
68
  if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
69
  require $file;
vendor/composer/autoload_static.php CHANGED
@@ -4,7 +4,7 @@
4
 
5
  namespace Composer\Autoload;
6
 
7
- class ComposerStaticInit0889502cf631a7b60d967a025f8b0e4c
8
  {
9
  public static $files = array (
10
  '7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php',
@@ -93,8 +93,8 @@ class ComposerStaticInit0889502cf631a7b60d967a025f8b0e4c
93
  ),
94
  'Psr\\Http\\Message\\' =>
95
  array (
96
- 0 => __DIR__ . '/..' . '/psr/http-message/src',
97
- 1 => __DIR__ . '/..' . '/psr/http-factory/src',
98
  ),
99
  'Psr\\Http\\Client\\' =>
100
  array (
@@ -534,9 +534,9 @@ class ComposerStaticInit0889502cf631a7b60d967a025f8b0e4c
534
  public static function getInitializer(ClassLoader $loader)
535
  {
536
  return \Closure::bind(function () use ($loader) {
537
- $loader->prefixLengthsPsr4 = ComposerStaticInit0889502cf631a7b60d967a025f8b0e4c::$prefixLengthsPsr4;
538
- $loader->prefixDirsPsr4 = ComposerStaticInit0889502cf631a7b60d967a025f8b0e4c::$prefixDirsPsr4;
539
- $loader->classMap = ComposerStaticInit0889502cf631a7b60d967a025f8b0e4c::$classMap;
540
 
541
  }, null, ClassLoader::class);
542
  }
4
 
5
  namespace Composer\Autoload;
6
 
7
+ class ComposerStaticInit0bb20f12ee9e70ddc31df259f96fd925
8
  {
9
  public static $files = array (
10
  '7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php',
93
  ),
94
  'Psr\\Http\\Message\\' =>
95
  array (
96
+ 0 => __DIR__ . '/..' . '/psr/http-factory/src',
97
+ 1 => __DIR__ . '/..' . '/psr/http-message/src',
98
  ),
99
  'Psr\\Http\\Client\\' =>
100
  array (
534
  public static function getInitializer(ClassLoader $loader)
535
  {
536
  return \Closure::bind(function () use ($loader) {
537
+ $loader->prefixLengthsPsr4 = ComposerStaticInit0bb20f12ee9e70ddc31df259f96fd925::$prefixLengthsPsr4;
538
+ $loader->prefixDirsPsr4 = ComposerStaticInit0bb20f12ee9e70ddc31df259f96fd925::$prefixDirsPsr4;
539
+ $loader->classMap = ComposerStaticInit0bb20f12ee9e70ddc31df259f96fd925::$classMap;
540
 
541
  }, null, ClassLoader::class);
542
  }