PluginProbe
Automatic YouTube Gallery – Embed Auto-Updating YouTube Video Galleries, Feeds, Playlists & Channels / 2.3.8
Automatic YouTube Gallery – Embed Auto-Updating YouTube Video Galleries, Feeds, Playlists & Channels v2.3.8
2.9.1 2.9.0 trunk 1.0.0 1.1.0 1.2.0 1.3.0 1.4.0 1.5.0 1.6.0 1.6.1 1.6.2 1.6.3 1.6.4 1.6.5 2.0.0 2.1.0 2.2.0 2.3.2 2.3.3 2.3.5 2.3.6 2.3.8 2.3.9 2.4.3 All 37 releases
← All changes | freemius/includes/managers/class-fs-plugin-manager.php +17 -4 1.6.1 → 2.3.8 View file →
@@ -210,11 +210,24 @@
210 210 *
211 211 * @return bool|\FS_Plugin
212 212 */
213 213 function get() {
214 - return isset( $this->_module ) ?
215 - $this->_module :
216 - false;
217 - }
214 + if ( isset( $this->_module ) ) {
215 + return $this->_module;
216 + }
218 217
218 + if ( empty( $this->_module_id ) ) {
219 + return false;
220 + }
219 221
222 + /**
223 + * Return an FS_Plugin entity that has its `id` and `is_live` properties set (`is_live` is initialized in the FS_Plugin constructor) to avoid triggering an error that is relevant to these properties when the FS_Plugin entity is used before the `parse_settings()` method is called. This can happen when creating a regular WordPress site by cloning a subsite of a multisite network and the data that is stored in the network-level storage is not cloned.
224 + *
225 + * @author Leo Fajardo (@leorw)
226 + * @since 2.5.0
227 + */
228 + $plugin = new FS_Plugin();
229 + $plugin->id = $this->_module_id;
230 +
231 + return $plugin;
232 + }
220 233 }