Code Duplication    Length = 14-14 lines in 7 locations

application/modules/xbanners/models/Base/BannerImage.php 1 location

@@ 389-402 (lines=14) @@
386
     * Clean up internal collections prior to serializing
387
     * Avoids recursive loops that turn into segmentation faults when serializing
388
     */
389
    public function __sleep()
390
    {
391
        $this->clearAllReferences();
392
393
        $cls = new \ReflectionClass($this);
394
        $propertyNames = [];
395
        $serializableProperties = array_diff($cls->getProperties(), $cls->getProperties(\ReflectionProperty::IS_STATIC));
396
397
        foreach($serializableProperties as $property) {
398
            $propertyNames[] = $property->getName();
399
        }
400
401
        return $propertyNames;
402
    }
403
404
    /**
405
     * Get the [id] column value.

application/modules/xbanners/models/Base/BannerImageI18n.php 1 location

@@ 344-357 (lines=14) @@
341
     * Clean up internal collections prior to serializing
342
     * Avoids recursive loops that turn into segmentation faults when serializing
343
     */
344
    public function __sleep()
345
    {
346
        $this->clearAllReferences();
347
348
        $cls = new \ReflectionClass($this);
349
        $propertyNames = [];
350
        $serializableProperties = array_diff($cls->getProperties(), $cls->getProperties(\ReflectionProperty::IS_STATIC));
351
352
        foreach($serializableProperties as $property) {
353
            $propertyNames[] = $property->getName();
354
        }
355
356
        return $propertyNames;
357
    }
358
359
    /**
360
     * Get the [id] column value.

application/modules/xbanners/models/Base/Banners.php 1 location

@@ 369-382 (lines=14) @@
366
     * Clean up internal collections prior to serializing
367
     * Avoids recursive loops that turn into segmentation faults when serializing
368
     */
369
    public function __sleep()
370
    {
371
        $this->clearAllReferences();
372
373
        $cls = new \ReflectionClass($this);
374
        $propertyNames = [];
375
        $serializableProperties = array_diff($cls->getProperties(), $cls->getProperties(\ReflectionProperty::IS_STATIC));
376
377
        foreach($serializableProperties as $property) {
378
            $propertyNames[] = $property->getName();
379
        }
380
381
        return $propertyNames;
382
    }
383
384
    /**
385
     * Get the [id] column value.

application/modules/xbanners/models/Base/BannersI18n.php 1 location

@@ 323-336 (lines=14) @@
320
     * Clean up internal collections prior to serializing
321
     * Avoids recursive loops that turn into segmentation faults when serializing
322
     */
323
    public function __sleep()
324
    {
325
        $this->clearAllReferences();
326
327
        $cls = new \ReflectionClass($this);
328
        $propertyNames = [];
329
        $serializableProperties = array_diff($cls->getProperties(), $cls->getProperties(\ReflectionProperty::IS_STATIC));
330
331
        foreach($serializableProperties as $property) {
332
            $propertyNames[] = $property->getName();
333
        }
334
335
        return $propertyNames;
336
    }
337
338
    /**
339
     * Get the [id] column value.

application/modules/mod_link/models/Base/PageLink.php 1 location

@@ 340-353 (lines=14) @@
337
     * Clean up internal collections prior to serializing
338
     * Avoids recursive loops that turn into segmentation faults when serializing
339
     */
340
    public function __sleep()
341
    {
342
        $this->clearAllReferences();
343
344
        $cls = new \ReflectionClass($this);
345
        $propertyNames = [];
346
        $serializableProperties = array_diff($cls->getProperties(), $cls->getProperties(\ReflectionProperty::IS_STATIC));
347
348
        foreach($serializableProperties as $property) {
349
            $propertyNames[] = $property->getName();
350
        }
351
352
        return $propertyNames;
353
    }
354
355
    /**
356
     * Get the [id] column value.

application/modules/mod_link/models/Base/PageLinkProduct.php 1 location

@@ 302-315 (lines=14) @@
299
     * Clean up internal collections prior to serializing
300
     * Avoids recursive loops that turn into segmentation faults when serializing
301
     */
302
    public function __sleep()
303
    {
304
        $this->clearAllReferences();
305
306
        $cls = new \ReflectionClass($this);
307
        $propertyNames = [];
308
        $serializableProperties = array_diff($cls->getProperties(), $cls->getProperties(\ReflectionProperty::IS_STATIC));
309
310
        foreach($serializableProperties as $property) {
311
            $propertyNames[] = $property->getName();
312
        }
313
314
        return $propertyNames;
315
    }
316
317
    /**
318
     * Get the [link_id] column value.

application/modules/mod_link/models/Base/PageLinkProducts.php 1 location

@@ 302-315 (lines=14) @@
299
     * Clean up internal collections prior to serializing
300
     * Avoids recursive loops that turn into segmentation faults when serializing
301
     */
302
    public function __sleep()
303
    {
304
        $this->clearAllReferences();
305
306
        $cls = new \ReflectionClass($this);
307
        $propertyNames = [];
308
        $serializableProperties = array_diff($cls->getProperties(), $cls->getProperties(\ReflectionProperty::IS_STATIC));
309
310
        foreach($serializableProperties as $property) {
311
            $propertyNames[] = $property->getName();
312
        }
313
314
        return $propertyNames;
315
    }
316
317
    /**
318
     * Get the [link_id] column value.