Code Duplication    Length = 10-10 lines in 2 locations

class/BaseSmartObject.php 2 locations

@@ 1412-1421 (lines=10) @@
1409
     * @param $key
1410
     * @return mixed
1411
     */
1412
    public function getUrlLinkObj($key)
1413
    {
1414
        $smartobjectLinkurlHandler = Smartobject\Helper::getInstance()->getHandler('Urllink');
1415
        $urllinkid                 = null !== $this->getVar($key) ? $this->getVar($key) : 0;
1416
        if (0 != $urllinkid) {
1417
            return $smartobjectLinkurlHandler->get($urllinkid);
1418
        } else {
1419
            return $smartobjectLinkurlHandler->create();
1420
        }
1421
    }
1422
1423
    /**
1424
     * @param $urlLinkObj
@@ 1438-1447 (lines=10) @@
1435
     * @param $key
1436
     * @return mixed
1437
     */
1438
    public function getFileObj($key)
1439
    {
1440
        $smartobjectFileHandler = Smartobject\Helper::getInstance()->getHandler('File');
1441
        $fileid                 = null !== $this->getVar($key) ? $this->getVar($key) : 0;
1442
        if (0 != $fileid) {
1443
            return $smartobjectFileHandler->get($fileid);
1444
        } else {
1445
            return $smartobjectFileHandler->create();
1446
        }
1447
    }
1448
1449
    /**
1450
     * @param $fileObj